write a C++ programming using for loop:
*
* *
* * *
* * * *
Answer Posted / debotri das
#include<iostream.h>
#include<conio.h>
void main()
{
clrscr();
int line,n,i;
cout<<"Enter no of line\n";
cin>>n;
for(line=1;line<=n;line++)
{
for(i=1;i<=line;i++)
{
cout<<" * ";
}
cout<<" \n ";
}
getch();
}
Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
What is the average salary of a c++ programmer?
What is cin clear () in c++?
Explain the differences between private, public and protected and give examples.
Why #include is used?
What does count ++ do in c++?
How can you specify a class in C++?
Is it possible to pass an object of the same class in place of object reference to the copy constructor?
what are the iterator and generic algorithms.
What is meant by the term name mangling in c++?
Why do we use structure in c++?
What is the difference between while and do while loop? Explain with examples.
What do you understand by zombie objects in c++?
What is the full form of ios?
How much is c++ certification?
What is constructor in C++?