文章目录
- AcWing 723. PUM
- AC代码
AcWing 723. PUM
本题链接:AcWing 723. PUM
本博客给出本题截图:
AC代码
代码:
#include <iostream> using namespace std; int main() { int n, m; cin >> n >> m; for (int i = 1; i <= n; i ++ ) { for(int j = 1; j <= m; j ++ ) { if (j == m) cout << "PUM"; else cout << j + m * (i - 1) << " "; } cout << endl; } return 0; }