In this C program we will print a Pattern of Asterisks, called "Half-Pyramid" on the screen.color>
*
**
***
****
*****
**
***
****
*****
input:
The number of rows- The Range.output:
The pattern will be printed on the screen.CODE---->
#include
color>int main()
{
int n,i,j;
printf(" Please, Enter the Range or the No. of Rows : color>");
scanf("%dcolor>",&n);
for(i=1color>;i;i++color>)
{
for(j=1color>;j;j++color>)
printf("*color>");
printf("\ncolor>");
}
return 0color>;
}
color>