Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
83268 刘宇轩 矩阵倒序输出 C++ Compile Error 0 MS 0 KB 370 2024-07-14 11:43:20

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int a[100][100]; int b[100][100]; int main(){ int n,m,c=0,d=0; cin>>n>>m; d=m-1; 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=m-1;j>=0;j--){ cout<<a[i][j]<<' '; } cout<<endl; } return 0;


Run Info:

Main.cc: In function 'int main()':
Main.cc:7:10: warning: unused variable 'c' [-Wunused-variable]
  int n,m,c=0,d=0;
          ^
Main.cc:7:14: warning: variable 'd' set but not used [-Wunused-but-set-variable]
  int n,m,c=0,d=0;
              ^
Main.cc:22:10: error: expected '}' at end of input
  return 0;
          ^