program to print this triangle
*
* *
* * *

Answers were Sorted based on User's Feedback



program to print this triangle * * * * * *..

Answer / rajesh

#include<stdio.h>
main()
{
int i,j;
for(i=1;i<=3;i++)
{
for(j=1;j<=i;j++)
printf(""+"*",i,j);
}
}

Is This Answer Correct ?    8 Yes 58 No

program to print this triangle * * * * * *..

Answer / jayasreesampath

#include<stdio.h>
main()
{
int i,j;
for(i=1;i<=3;i++)
{
for(j=1;j<=3;j++)
printf("\n",i,j);
}
}

Is This Answer Correct ?    23 Yes 91 No

Post New Answer

More C++ General Interview Questions

How do you differentiate between overloading the prefix and postfix increments?

0 Answers  


Is c++ double?

0 Answers  


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

5 Answers  


What are the different types of Storage classes?

5 Answers  


Why is swift so fast?

0 Answers  






What are the different operators in C++?

3 Answers   HP,


What is size of null class?

6 Answers   HP,


Why are arrays usually processed with for loop?

0 Answers  


What are the basic data types used in c++?

0 Answers  


Write about all the implicit member functions of a class?

0 Answers  


Difference between a homogeneous and a heterogeneous container

0 Answers  


Can member functions be private?

0 Answers  


Categories