hello everyone,
i need to modify these code:
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char *argv[])
{
int numOfStars = 0;
int count, counter;
do
{
printf("N=");
scanf ("%d",&numOfStars);
for( ; counter<=numOfStars; counter++)
{
for( ;numOfStars>0; numOfStars--)
{
if (numOfStars != 9999)
{
for (count = 0;count < numOfStars; count++)
{
printf("*");
}
printf("\n");
}
}
printf(" ");
}
}
while (numOfStars != 9999);
system("PAUSE");
return 0;
}
i already try this code but not getting the good result
i got
N=3
***
**
*
N=
i need to get a result like this
when enter 3 i need to get this result with the way it had displayed
N=3
***
**
*
any help
thanks