提交时间:2024-01-26 15:59:32

运行 ID: 129054

#include <bits/stdc++.h> using namespace std; int a[110][110]; int main(){ int n, m; cin >> n >> m; for(int i = 1; i <= n; i++){ for(int j = 1; j <= m; j++){ cin >> a[i][j]; } } for(int i = 1; i <= m; i++){ for(int j = 1; j <= n; j++){ cout << a[j][i] << " "; } cout << endl; } return 0; }