how do i write program like one shown
1234567654321
123456 654321
12345 54321
1234 4321
123 321
12 21
1 1
Answer Posted / amit
#include<stdio.h>
int main()
{
int i,j,n;
printf("Enter no");
scanf("%d",&n);
for(i=0;i<=n;i++)
{
for(j=1;j<=n-i;j++)
printf("%d",j);
for(j=0;j<2*i-1;j++)
printf(" ");
for(j=n-i;j>0;j--)
printf("%d",j);
printf("\n");
}
}
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
i am electronics & comm engg & appling 4 the AAI jr executive (electronics/ATC) written test. pls forward me the syllabus & old question papers.I will be very much thankful to you, snehalsanap@gmail.com
What is the distance from an RF Transmitter that output power is determined?
what is the bani fit of ss7 by using as a back bone for all other communication networks?
What are rlc circuits?
what should I refer for examination of BSNL-TTA. Please suggest me good reference...so that I can clear this exam.
I want previous rrb enteranse exam papers in section engineer. please send that papers to my id rohit_nist@yahoo.co.in
hi i am electronics & telecomm engg & appling 4 the AAI jr executive (electronics/ATC) written test. pls forward me the syllabus & old question papers.I will be very much thankful to you. das.nilanjana2000@gmail.com
i m a b.tech 2nd yr student.. i can be placed in my degree but still should i think for MBA?
Define octet?
Define negative logic.
Explain what is meant by virtual ground in the op amp?
Define drift current in a semiconductor.
What is a sequential circuit and what is a combinational circuit?
Explain the approximate cost of the smart pebbles eci-1(embedded corrosion instrument)?
Explain the difference between masking and non-masking?