write a C++ programming using for loop:
*
* *
* * *
* * * *

Answer Posted / devi

#include<iostream.h>
#include<conio.h>
void main()
{
int i,j;
clrscr();
for(i=1;i<=4;i++)
{
for(j=1;j<=i;j++)
{
cout<<"*";
}
cout<<"\n";
}
getch();
}

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the benefits of c++?

673


Explain shallow copy?

687


What is #include iomanip?

635


Inline parameters : What does the compiler do with the parameters of inline function, that can be evaluated in runtime ?

2099


How can we check whether the contents of two structure variables are same or not?

685






What is void pointer in c++ with example?

676


How do you flush a buffer in c++?

704


Why are arrays usually processed with for loop?

864


What is general format for a prototype?

690


. If employee B is the boss of A and C is the boss of B and D is the boss of C and E is the boss of D. Then write a program using the Database such that if an employee name is Asked to Display it also display his bosses with his name. For eg. If C is displayed it should also display D and E with C?

2879


Is c++ an integer?

673


How is objective c different from c++?

877


Define vptr.

680


What is atoi in c++?

664


Why cout is used in c++?

662