1 solutions
-
1
参考答案:
#include<iostream> using namespace std; int main() { char a = 'A', b, c; cin >> c; for (int i = a; i <= c; ++i) { for (int j = i; j < c; ++j) cout << ' '; for (int j = a; j <= i; ++j) printf("%c", j); for (int j = i - 1; j >= a; --j) printf("%c", j); cout << endl; } return 0; }
- 1
Information
- ID
- 1571
- Time
- 1000ms
- Memory
- 256MiB
- Difficulty
- 8
- Tags
- # Submissions
- 16
- Accepted
- 6
- Uploaded By