Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
148280 王梓宇 数组输出 C++ Compile Error 0 MS 0 KB 511 2026-02-11 08:18:04

Tests(0/0):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ numbers = [] print("请输入10个整数:") for i in range(10): num = int(input(f"请输入第 {i + 1} 个整数:")) numbers.append(num) print("你输入的整数为:") for num in numbers: print(num) return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:9:4: error: 'numbers' was not declared in this scope
    numbers = []
    ^
Main.cc: In lambda function:
Main.cc:10:1: error: expected '{' before 'print'
 print("请输入10个整数:")
 ^