January 27th, 2004, 06:21 PM
how to print a triangle by using while loop in c??
Write a program that uses one or more while statements to create the following output:
January 27th, 2004, 07:08 PM
void draw_triangle(int size)
for (int i=0; i<size; i++)
for (int j=0; j<i; j++) printf("*");
January 27th, 2004, 07:12 PM
lazy_yogi, you shouldn't do homework for these guys! At least they could search through the archives and get the solution from the 50 other times one was posted.
January 27th, 2004, 08:48 PM
hkboy, I suggest you put forth some effort in your studies. You'll get NOWHERE going to other people for solutions. We're here to help you along, NOT solve your homework problems.*
*Well. . .most of us aren't here to do your homework. :rolleyes:
January 28th, 2004, 01:33 AM
mitakeet: Yeh you're right. didn't think of that.
tho having said that, it can be hard to do the very basics for a new programmer who has no past domain specific knowledge to draw on.
But yea, I should have left it for him to alteast try start on before helping