output
12345
1234
123
12
1
12
123
1234
12345
#include<stdio.h>
void main()
{
int i,j,k,l;
printf("enter the row value:-");
scanf("%d",&l);
for(i=l;i>1;i--)
{
for(j=1;j<=i;j++)
{
printf("%d",j);
// printf("%d",&j);
}
printf("\n");
}
for(i=1;i<=l;i++)
{
for(j=1;j<=i;j++)
{
printf("%d",j);
// printf("%d",&j);
}
printf("\n");
}
}
Optional default code goes here

0 Comments