Program Source Code
#include"stdio.h"
#include"conio.h"
void main()
{
int i,j,n,k;
printf (“Enter the value of n”);
scanf(“%d”,&n);
for(i=1;i<=n;i++)
{
for(j=1;j<=n-1;j++)
{
printf(“ ”);
}
for(k=1;k<=i;k++)
{
printf(“* ”);
}
printf(“\n”);
}
getch();
}
1 comment:
can you write me a C code for this pattern -
*
* * *
* * * * *
* * * * *
* * *
*
please... Thanx in advance
Post a Comment
Dont SPAM