/* C Program to print half pyramid using */
#include <stdio.h>
int main()
{
int p, k, number;
printf("Enter number of rows :");
scanf("%d",&number);
for(p=0; p<=number;p++)
{
for(k=0; k<p; k++)
{
printf("
*");
}
printf("\n");
}
return 0;
}
Output
|
Program To Print Half Pyramid Using *. |
No comments:
Post a Comment