fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. // your code goes here
  6. int n;cin>>n;
  7.  
  8. for(int i =1;i<=n;i++){
  9. for(int j =n-i; j>=0;j--){
  10. cout<<n-i+1;
  11. }
  12.  
  13. cout<<endl;
  14. }
  15. return 0;
  16. }
Success #stdin #stdout 0s 5316KB
stdin
3
stdout
333
22
1