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

int main()
{
cout<<"1\n2 1\n3 2 1\n4 3 2 1\n5 4 3 2 1\n6 5 4 3 2 1";
return 0;
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by friend class & friend function in c++?

707


What size is allocated to the union variable?

683


What do you understand by zombie objects in c++?

719


Does there exist any other function which can be used to convert an integer or a float to a string?

731


What are c++ variables?

626






How to demonstrate the use of a variable?

718


Perform addition, multiplication, subtraction of 2-D array using Operator Overloading.

3444


What are static and dynamic type checking?

704


What is function overloading in C++?

813


How does a copy constructor differs from an overloaded assignment operator?

669


When should I use unitbuf flag?

683


Why iomanip is used in c++?

738


What is endl c++?

706


Is c++ double?

653


What do you mean by volatile and mutable keywords used in c++?

676