记录详情

Compile Error

foo.c: In function 'main':
foo.c:7:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
  int i,sum1.sum2,sum3,sum;
            ^
foo.c:11:3: error: 'sum1' undeclared (first use in this function)
   sum1++;}
   ^~~~
foo.c:11:3: note: each undeclared identifier is reported only once for each function it appears in
foo.c:15:2: error: 'sum2' undeclared (first use in this function); did you mean 'sum1'?
  sum2++;}
  ^~~~
  sum1
foo.c:20:2: error: 'sum3' undeclared (first use in this function); did you mean 'sum2'?
  sum3++;}
  ^~~~
  sum2
foo.c:24:9: error: expected statement before ')' token
  {b*=10;)
         ^
foo.c:27:3: error: 'sum' undeclared (first use in this function); did you mean 'sum3'?
   sum=a+b+c;
   ^~~
   sum3
foo.c:30:1: error: expected declaration or statement at end of input
 }
 ^
foo.c:6:5: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
     scanf("%d%d%d",&a,&b,&c);
     ^~~~~~~~~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1227 C11 三数合成一数
语言
C
递交时间
2021-11-25 15:42:24
评测时间
2021-11-25 15:42:24
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes