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...

write the code that display the format just like
1
2 1
3 2 1
4 3 2 1
5 4 3 2 1
6 5 4 3 2 1

Answer Posted / prasenjit roy

int main()
{
int i;
int j;
for(i = 1; i <= 6; i++)
{
for(j = i; j >= 1; j--)
cout<<j<<" ";
cout<<endl;
}
return 0;
}

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is const pointer and const reference?

1105


Explain function overloading and operator overloading.

1037


Difference between overloading vs. Overriding

1050


What is c++ stringstream?

1066


What do you mean by persistent and non persistent objects?

1386


What are the types of container classes?

1106


What is java and c++?

1134


What is the advantage of c++ over c?

983


Explain one-definition rule (odr).

1079


Can comments be longer than one line?

1029


What are the steps in the development cycle?

1053


why is c++ called oops? Explain

1000


When do we run a shell in the unix system?

1033


What is an associative container in c++?

1019


What are the advantages of using pointers in a program?

1114