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 / gayatri chhotray
int main()
{
int i;
int j;
for(i = 1; i <= 6; i++)
{
for(j = i; j >= 1; j--)
{
cout<<j<<" ";
}
}
return 0;
}
| Is This Answer Correct ? | 4 Yes | 4 No |
Post New Answer View All Answers
What is meant by iomanip in c++?
What are the benefits of oop in c++?
What is command line arguments in C++? What are its uses? Where we have to use this?
Does c++ have a hash table?
What is a class template in c++?
How do you establish a has-a relationship?
How to tokenize a string in c++?
What is &x in c++?
How can I improve my c++ skills?
What is the difference between the functions memmove() and memcpy()?
Write a program that takes a 5 digit number and calculates 2 power that number and prints it.
Is c++ free?
Write a recursive program to calculate factorial in c++.
Describe exception handling concept with an example?
Which header file allows file i/o with streams a) fileio.h b) iostream.h c) fstream.h