5 c.) Program to print this :

 

/* program to print the :
1
12
123
1234
12345*/
#include<stdio.h>
#include<conio.h>
int main()
{
    int i,j;
    for(i=1;i<=5;i++) // this loop use for lines.
    {
        for(j=1;j<=i;j++) // this loop is use for print the number.
        {
            printf("%d",j);
        }
        printf("\a\n");
    }
    return 0;
}

Output:
1
12
123
1234
12345
***** Thank you *****

Comments

Popular posts from this blog

18 Amazing programs in C.