print pattern
1 1
33 33
555 555
77777777
555 555
33 33
1 1

Answer Posted / kiran kumar

#include<stdio.h>
main()
{
int i,j,space=6,val=1;
for(i=0;i<4;i++)
{
for(j=0;j<=i;j++)
printf("%d",val);
for(j=0;j<space;J++)
printf(" ");
for(j=0;j<=i;j++)
printf("%d",val);
space-=2;
val+=2;
}
repeat code once again;

space+=2;
val-=2

}

Is This Answer Correct ?    2 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of ?: Operator?

660


how do you programme Carrier Sense Multiple Access

1510


What is self-referential structure in c programming?

655


What are the types of data types and explain?

665


C program to find all possible outcomes of a dice?

1851






Why do we need arrays in c?

577


What is the purpose of sprintf?

615


develop algorithms to add polynomials (i) in one variable

1735


What does do in c?

606


c programs are converted into machine language with the help of a) an interpreter b) a compiler c) an operatinf system d) none of the above

725


What is the use of bit field?

635


How can I call a function with an argument list built up at run time?

631


#define PRINT(int) printf("int = %d ",int) main() {< BR> intx,y,z; x=03;y=02;z=01; PRINT(x^x); z<<=3;PRINT(x); y>>=3;PRINT(y); }

713


#include main() { enum _tag{ left=10, right, front=100, back}; printf("left is %d, right is %d, front is %d, back is %d",left,right,front,back); }

710


What is structure of c program?

599