记录详情

Compile Error

/in/foo.c: In function 'main':
/in/foo.c:7:6: error: conflicting types for 'a'
  int a[100],h[10];
      ^
/in/foo.c:6:8: note: previous declaration of 'a' was here
  int m,a,b,c,j;
        ^
/in/foo.c:27:3: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
   if(a[i]=a[i+1])
   ^~
/in/foo.c:31:3: error: assignment to expression with array type
  a=0;
   ^
/in/foo.c:34:11: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
   c=a[i],j=a;
           ^
/in/foo.c:37:7: error: lvalue required as increment operand
      a++;
       ^~
/in/foo.c:38:7: warning: comparison between pointer and integer
   if(a>j)
       ^
/in/foo.c:39:5: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
    j=a;
     ^
/in/foo.c:41:3: error: assignment to expression with array type
  a=j;
   ^
/in/foo.c:44:11: warning: format '%d' expects argument of type 'int', but argument 2 has type 'int *' [-Wformat=]
  printf("%d\n",a);
           ^
/in/foo.c:7:13: warning: unused variable 'h' [-Wunused-variable]
  int a[100],h[10];
             ^

信息

递交者
类型
递交
题目
P1204 水滴
比赛
2020年互联网创新创业科技节程序设计大赛
语言
C
递交时间
2020-12-09 15:17:22
评测时间
2020-12-09 15:17:22
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes