| Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 72532 | sh25_ganzy | 矩阵交换行 | C++ | 解答错误 | 0 MS | 256 KB | 619 | 2025-11-01 18:39:55 |
#include<bits/stdc++.h> using namespace std; int main(){ int m,n,a[5][5]; for(int i=0;i<5;i++){ for(int j=0;j<5;j++){ cin>>a[i][j]; } } cin>>m>>n; for(int i=0;i<5;i++){ if(i!=m&&i!=n){ for(int j=0;j<5;j++){ cout<<a[i][j]<<" "; } }else if(i==m){ for(int j=0;j<5;j++){ cout<<a[n][j]<<" "; } }else if(i==n){ for(int j=0;j<5;j++){ cout<<a[m][j]<<" "; } } cout<<endl; } return 0; }