Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
26162 liuyuchen 矩阵转置 C++ 解答错误 0 MS 256 KB 295 2023-08-30 15:46:29

Tests(0/1):


#include<iostream> using namespace std; int main() { int n,m; cin>>n>>m; int a[n][m]; for(int i=0;i<n;i++){ for(int j=0;j<m;j++){ cin>>a[i][j]; } } for(int i=0;i<n;i++){ for(int j=0;j<m;j++){ cout<<a[i][j]<<" "; } cout<<endl; } return 0; }


测评信息:

输入

3 3
1 2 3
4 5 6
7 8 9

输出

1 2 3 
4 5 6
7 8 9

答案

1 4 7
2 5 8
3 6 9

系统信息

exit code: 0, checker exit code: 0