Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
120095 | 谭思宸 | 外围元素之和 | C++ | Compile Error | 0 MS | 0 KB | 284 | 2025-05-24 10:17:31 |
#include<bits/stdc++.h> using namespace std; int main(){ int sum=0; for(int i=0;i<n;i++){ for(int j=0;j<m;j++){ if(i==0||i=n-1){ sum=sum+a[i][j]; }else{ if(j==0||j==m-i){ sum=sum+a[i][j]; } } } }
Main.cc: In function 'int main()': Main.cc:5:19: error: 'n' was not declared in this scope for(int i=0;i