Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

C-Program of Printing Half Pyramid using *(Asterisk)

Tags: row



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>;
}




Don't just read, write it, run it.....color>

RESULT:color>





This post first appeared on ProgramJoy.blogspot.com, please read the originial post: here

Share the post

C-Program of Printing Half Pyramid using *(Asterisk)

×

Subscribe to Programjoy.blogspot.com

Get updates delivered right to your inbox!

Thank you for your subscription

×