| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 158144 | 王垚植 | 打印数字图形 | C++ | Wrong Answer | 1 MS | 272 KB | 561 | 2026-08-20 16:47:07 |
#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; for (int i=0;i<n;i++){ for (int j=0;j<n-i-1;j++){ cout<<" "; } for (int j=0;j<i+1;j++){ cout<<j; } for (int j=i+1;j>0;j--){ cout<<j; } } for (int i=n;i>n;i--){ for (int j=0;j<n-i;j++){ cout<<" "; } for (int j=0;j<i+1;j++){ cout<<j; } for (int j=i+1;j>0;j--){ cout<<j; } } return 0; }
------Input------
8
------Answer-----
1 121 12321 1234321 123454321 12345654321 1234567654321 123456787654321 1234567654321 12345654321 123454321 1234321 12321 121 1
------Your output-----
01 0121 012321 01234321 0123454321 012345654321 012345676543210123456787654321