Computer Science, asked by cutiepie378510, 10 months ago

10. Write a program to print a pattern using nested if loop as :
* * * * *
* * * *
* * *
* *
*
* *
* * *
* * * *
* * * * *

Answers

Answered by suhuuzzz
7

Answer:

#include<iostream>

Using namespace std;

Int main()

{

Int i, j;

for(i=1; i<=5; i++)

{

Cout<<"\n" ;

for(j=1; j<=i; j++)

{

Cout<<"*" ;

If(j==3)

Break;

}

}

Similar questions