Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

My awesome C++ triangle

Name: GOD_HATES_THE_JEWS 2012-02-18 10:49

//Homework 2, question 5

#include <iostream>
using namespace std;

int main(void)
{
 int n;
 int r, c;

 cout << "Enter a number: ";
 cin >> n;
 
 n = 2 * n + 2;
 
 for (r = 1; r <=n; r++, cout << endl)
     for (c = 1; c <=n; c++)
         cout << (r==1 || r==n || c==1 || c==n
              || r >= c || (r+c < n+1) ? ' ' : '*');

 return 0;  
}

Name: Anonymous 2012-02-19 0:09

>>22
That is you who things creating text triangles are difficult
Do you mean ``thinks''? And I never said it was difficult, I said it was easy, you're the one who thought it was a monumental challenge you dumb piece of shit.

>>23
I don't look at the code of shitty toy projects like Apache, sorry.

>>24
You're the lippy one you fucking faggot, all you have done is to claim that you contributed code to some unscalable shit that performs poorly like Apache. I don't see any proof in this thread you fucking retard.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List