CPP
cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <iostream>
#include<iomanip>
using namespace std;
int main() {
for(int b=0;b<5;b++){
for(int f=4;f>b;f--)
cout<<" ";
for(int o=0;o<2*b+1;o++){
cout<<setw(3)<<"*";}
cout<<endl;}
return 0;
}
Enter to Rename, Shift+Enter to Preview
OUTPUT
Run