Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
64529 许铭锐 拐角方阵 C++ Compile Error 0 MS 0 KB 418 2024-01-21 16:17:54

Tests(0/0):


Code:

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


Run Info:

Main.cc: In function 'int main()':
Main.cc:13:21: error: 'j' was not declared in this scope
   for(int i=k; i