PROGRAM TO PRINT A SEQUENCE OF STARS

/*PROGRAM TO PRINT A SEQUENCE OF STARS*/
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j;
clrscr();
printf(“Press any key to display the pattern: \n”);
getch();
for(i=1;i<=4;i++)
{
for(j=1;j<=i;j++)
printf(“*”);
printf(“\n”);
}
getch();
}

Leave a Reply

Your email address will not be published. Required fields are marked *