Google Ads

Friday, May 29, 2009

Stars2 - program

To print decreasing the stars

#include"stdio.h"
#include"conio.h"
void main()
{
int i,j;
clrscr();
for(i=5;i<6;i--)
{
for(j=0;j<=i;j++)
{
printf(" * ");
}
printf("\n");
}

getch();

}

Output will be
*****
****
***
**
*

No comments:

Post a Comment