Skip to main content

Posts

WAP to generate the following pattern in C

WAP to generate the following pattern   n=4  4444    i=4  333      i=3  22       i=2  1        i=1  #include<stdio.h> #include<conio.h> main( ) {             int i,j,n;             clrscr();             printf("\nEnter the value of n:");             scanf("%d",&n);             for(i=n;i>=1;i--)             {                         for(j=1;j<=i;j++)      ...

WAP to generate the following pattern using for loop in C

WAP to generate the following pattern   n=4   1  22   333 4444  #include<stdio.h> #include<conio.h> main( ) {             int i,j,n,sp;             clrscr();             printf("\nEnter the value of n:");             scanf("%d",&n);             sp=n-1;             for(i=1;i<=n;i++)             {                         for(j=1;j<=sp;j++)         ...

WAP to read the value of n and generate the following pattern using for loop in C

/* WAP to read the value of n and generate the following  pattern    n=4   1234  123 12 1   #include<stdio.h> #include<conio.h> main() {             int i,j,n;             clrscr();             printf("\nEnter the value of n:");             scanf("%d",&n);             for(i=n;i>=1;i--)             {                         for(j=1;j<=i;j++)                   ...

WAP to read the value of n and generate the following pattern using for loop in C

WAP to read the value of n and generate the following pattern   n=4   1   12   123   1234 */ #include<stdio.h> #include<conio.h> main() {             int i,j,n;             clrscr();             printf("\nEnter the value of n:");             scanf("%d",&n);             for(i=1;i<=n;i++)             {                         for(j=1;j<=i;j++)                ...

WAP to read the value of n and generate the following pattern in c using for loop

WAP to read the value of n and generate the following pattern using for loop in C.   n=4   ****   ***  **   * #include<stdio.h> #include<conio.h> main() {             int i,j,n;             clrscr();             printf("\nEnter the value of n:");             scanf("%d",&n);             for(i=n;i>=1;i--)             {                         for(j=1;j<=i;j++)               ...