+ 1
Shape
#include <iostream> using namespace std; int main() { int i,j,k; for(i=1;i<=4;i++) { for(k=3;k>=i;k--) cout<<"-"; for(j=1;j<=i;j++) cout<<j; cout<<endl; } return 0; } hey how can I make ---1 --21 -321 4321 inestead of ---1 --12 -123 1234
4 Antworten
+ 3
replace last for loop by:-
for(j=i;j>=1;j--)
+ 2
Anytime :-)
+ 1
it's work 👍
thanx😊