program to print this triangle
*
* *
* * *
Answer Posted / saravana kumar
void main()
{
int i , j , k ;
for(i = 0 ; i < 3 ; i++)
{
for (k = 2 ; k >= i ; k--)
{
printf (" ") ;
}
for(j = 0 ; j<= i ; j++)
{
printf ("* " , i , j) ;
}
printf ("\n") ;
}
| Is This Answer Correct ? | 7 Yes | 13 No |
Post New Answer View All Answers
Write about the various sections of the executable image?
What is a Default constructor?
What is the difference between structure and class?
What is a v-table?
Write about all the implicit member functions of a class?
What are the various storage classes in C++?
What are manipulators used for?
What is input operator in c++?
What do you mean by function and operator overloading in c++?
what is a reference variable in C++?
Evaluate !(1&&1||1&&0) a) Error b) False c) True
What is a type library?
What is endl?
Explain rtti.
What is data binding in c++?