Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
137822 张咏灏 【基础题】求和(1) C++ Compile Error 0 MS 0 KB 148 2025-11-22 17:31:26

Tests(0/0):


Code:

#include<iostream> using namespace std; int main(){ int a0; for(int i=12;i<1002;i+=10){ a+=;i } cout<<a; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:6:3: error: 'a' was not declared in this scope
   a+=;i
   ^
Main.cc:6:6: error: expected primary-expression before ';' token
   a+=;i
      ^
Main.cc:7:5: error: expected ';' before '}' token
     }
     ^
Main.cc:7:5: warning: statement has no effect [-Wunused-value]
Main.cc:8:11: error: 'a' was not declared in this scope
     cout<