记录详情

Compile Error

/in/foo.c: In function 'main':
/in/foo.c:6:19: warning: format '%c' expects a matching 'char *' argument [-Wformat=]
    6 |         scanf("%d%c%d",&a);
      |                  ~^
      |                   |
      |                   char *
/in/foo.c:6:21: warning: format '%d' expects a matching 'int *' argument [-Wformat=]
    6 |         scanf("%d%c%d",&a);
      |                    ~^
      |                     |
      |                     int *
/in/foo.c:8:18: warning: left shift count >= width of type [-Wshift-count-overflow]
    8 |         if(500<<a<<1000){
      |                  ^~
/in/foo.c:8:18: warning: '<<' in boolean context, did you mean '<'? [-Wint-in-bool-context]
    8 |         if(500<<a<<1000){
      |            ~~~~~~^~~~~~
/in/foo.c:11:32: warning: left shift count >= width of type [-Wshift-count-overflow]
   11 |                 else if(1000<<a<<1500){
      |                                ^~
/in/foo.c:11:32: warning: '<<' in boolean context, did you mean '<'? [-Wint-in-bool-context]
   11 |                 else if(1000<<a<<1500){
      |                         ~~~~~~~^~~~~~
/in/foo.c:14:24: warning: left shift count >= width of type [-Wshift-count-overflow]
   14 |         else if(1500<<a<<2000){
      |                        ^~
/in/foo.c:14:24: warning: '<<' in boolean context, did you mean '<'? [-Wint-in-bool-context]
   14 |         else if(1500<<a<<2000){
      |                 ~~~~~~~^~~~~~
/in/foo.c:17:18: warning: right shift count >= width of type [-Wshift-count-overflow]
   17 |         else if(a>>2000){
      |                  ^~
/in/foo.c:20:17: error: expected ';' before '}' token
   20 |         return 0
      |                 ^
      |                 ;
   21 | }
      | ~                

信息

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