Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
140122 田祥江 矩阵旋转 C++ Compile Error 0 MS 0 KB 325 2025-12-13 15:48:07

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int a[1000][1000]; int main(){ int n,m; scanf("%d%d",&n,&m) for(int i=1;i<=n;i++){ for(int j=1;j<=m;j++){ scanf("%d",&a[i][j]); } } for(int j=1;j<=m;j++){ for(int i=1;i<=n;j--){ printf("%d",a[i][j]); } printf("\n"); } }


Run Info:

Main.cc: In function 'int main()':
Main.cc:7:6: error: expected ';' before 'for'
      for(int i=1;i<=n;i++){
      ^
Main.cc:7:18: error: 'i' was not declared in this scope
      for(int i=1;i<=n;i++){
                  ^
Main.cc:7:17: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
      for(int i=1;i<=n;i++){
                 ^