记录详情

Compile Error

/in/foo.cc: In function 'int main()':
/in/foo.cc:6:7: error: expected ';' before 'x'
    6 |    cin x;
      |       ^~
      |       ;
/in/foo.cc:6:4: warning: statement has no effect [-Wunused-value]
    6 |    cin x;
      |    ^~~
/in/foo.cc:7:4: error: 'if\U0000ff08x' was not declared in this scope
    7 |    if(x>=2000);
      |    ^~~~~
/in/foo.cc:8:8: error: expected ';' before numeric constant
    8 |    cout 0.8x;
      |        ^~~~~
      |        ;
/in/foo.cc:8:4: warning: statement has no effect [-Wunused-value]
    8 |    cout 0.8x;
      |    ^~~~
/in/foo.cc:9:4: error: 'else' without a previous 'if'
    9 |    else if(x>=1500);
      |    ^~~~
/in/foo.cc:10:8: error: expected ';' before numeric constant
   10 |    cout 0.85x;
      |        ^~~~~~
      |        ;
/in/foo.cc:10:4: warning: statement has no effect [-Wunused-value]
   10 |    cout 0.85x;
      |    ^~~~
/in/foo.cc:11:4: error: 'else' without a previous 'if'
   11 |    else if (x>=1000);
      |    ^~~~
/in/foo.cc:12:8: error: expected ';' before numeric constant
   12 |    cout 0.9x;
      |        ^~~~~
      |        ;
/in/foo.cc:12:4: warning: statement has no effect [-Wunused-value]
   12 |    cout 0.9x;
      |    ^~~~
/in/foo.cc:13:4: error: 'else' without a previous 'if'
   13 |    else if (x>=500);
      |    ^~~~
/in/foo.cc:14:8: error: expected ';' before numeric constant
   14 |    cout 0.95x;
      |        ^~~~~~
      |        ;
/in/foo.cc:14:4: warning: statement has no effect [-Wunused-value]
   14 |    cout 0.95x;
      |    ^~~~

信息

递交者
类型
递交
题目
P1019 contest1-4 超市促销活动
比赛
2026-11-13 C++实测1
语言
C++
递交时间
2026-11-13 20:17:09
评测时间
2026-11-13 20:17:09
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes