Contact Learn C
Copy

Program 356:Generate Given Numerical Pattern 6

Program 356:Generate Given Numerical Pattern 6
 
#include<stdio.h>
main()
{
    int i,j,num,k,count;
    printf("Enter number of rows\n");
    scanf("%d",&num);
    count=num-1;
    for(i=1;i<=num;i++)
    {
    for(k=1;k<=count;k++)
    {
        printf(" ");
    }
        for(j=i;j>=1;j--)
        {
            printf("%d",j);
           
        }
        
    printf("\n");
    count--;
    }
}
Enter number of rows
5
    1
   21
  321
 4321
54321
Explanation:

//Coming Soon...

 Output:

Generate Given Numerical Pattern 6
Donate

Download App and Learn when ever you want

Get it on PlayStore
Get it on Amazon App Store
Get it on Aptoide