Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
143059 周润泽 [在线测评解答教程] 求和 C++ Compile Error 0 MS 0 KB 186 2026-01-11 18:42:55

Tests(0/0):


Code:

#include <iostream> using namespace std; int main() { int n; int j=0; cin>>n; for(int i=1;i<=n;i++){ j+=a[i]; } cout<<j<<endl; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:9:12: error: 'a' was not declared in this scope
         j+=a[i];
            ^