Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


how do i write program like one shown
1234567654321
123456 654321
12345 54321
1234 4321
123 321
12 21
1 1

Answers were Sorted based on User's Feedback



how do i write program like one shown 1234567654321 123456 654321 12345 54321 1234 4321 ..

Answer / ayshu

it can be done using nested for loop

Is This Answer Correct ?    20 Yes 3 No

how do i write program like one shown 1234567654321 123456 654321 12345 54321 1234 4321 ..

Answer / swathi

we have to use nested for loops and also some predefined
functions which makes the cursor to jump to new location or
else \n,]b can be used in c pragram

Is This Answer Correct ?    8 Yes 3 No

how do i write program like one shown 1234567654321 123456 654321 12345 54321 1234 4321 ..

Answer / cinu

#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;j++)
printf(" ");
for(j=n-i;j>0;j--)
printf("%d",j);

printf("\n");
}
}

Is This Answer Correct ?    9 Yes 6 No

how do i write program like one shown 1234567654321 123456 654321 12345 54321 1234 4321 ..

Answer / 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

More Electronics Communications Interview Questions

Why do we need Interview?

0 Answers  


what is VSWR?

3 Answers   Ericsson,


what is that functionality of a relay? draw aconnection for relay?

1 Answers  


14,25,49,169

1 Answers  


Explain the differences between voltage and current controlled devices?

0 Answers  


How can the race-around problem be solved?

0 Answers  


What is tunnel diode?

0 Answers  


What are the standards for the following :RS-23-C 802.3 X.25 802.11 ?

3 Answers  


Write the total description of Ultra Commissioning.

0 Answers   NSN,


dummy strain guage

0 Answers   ONGC,


Explain about diode in a brief manner..

4 Answers   Toshiba,


What is meant by duty-cycle?

0 Answers  


Categories
  • Civil Engineering Interview Questions Civil Engineering (5086)
  • Mechanical Engineering Interview Questions Mechanical Engineering (4456)
  • Electrical Engineering Interview Questions Electrical Engineering (16639)
  • Electronics Communications Interview Questions Electronics Communications (3918)
  • Chemical Engineering Interview Questions Chemical Engineering (1095)
  • Aeronautical Engineering Interview Questions Aeronautical Engineering (239)
  • Bio Engineering Interview Questions Bio Engineering (96)
  • Metallurgy Interview Questions Metallurgy (361)
  • Industrial Engineering Interview Questions Industrial Engineering (259)
  • Instrumentation Interview Questions Instrumentation (3014)
  • Automobile Engineering Interview Questions Automobile Engineering (332)
  • Mechatronics Engineering Interview Questions Mechatronics Engineering (97)
  • Marine Engineering Interview Questions Marine Engineering (124)
  • Power Plant Engineering Interview Questions Power Plant Engineering (172)
  • Textile Engineering Interview Questions Textile Engineering (575)
  • Production Engineering Interview Questions Production Engineering (25)
  • Satellite Systems Engineering Interview Questions Satellite Systems Engineering (106)
  • Engineering AllOther Interview Questions Engineering AllOther (1379)