记录详情

Compile Error

foo.c: In function 'SetInter':
foo.c:9:3: warning: implicit declaration of function 'Sort' [-Wimplicit-function-declaration]
    9 |   Sort(a1, n1);
      |   ^~~~
foo.c: At top level:
foo.c:36:6: warning: conflicting types for 'Sort'; have 'void(int *, int)'
   36 | void Sort(int a[], int n)
      |      ^~~~
foo.c:9:3: note: previous implicit declaration of 'Sort' with type 'void(int *, int)'
    9 |   Sort(a1, n1);
      |   ^~~~
foo.c: In function 'main':
foo.c:60:18: error: 'n1' undeclared (first use in this function); did you mean 'm1'?
   60 |     scanf("%d", &n1);
      |                  ^~
      |                  m1
foo.c:60:18: note: each undeclared identifier is reported only once for each function it appears in
foo.c:61:22: error: 'n2' undeclared (first use in this function); did you mean 'm2'?
   61 |         scanf("%d", &n2);
      |                      ^~
      |                      m2
foo.c:62:18: error: 'n3' undeclared (first use in this function); did you mean 'a3'?
   62 |     scanf("%d", &n3);
      |                  ^~
      |                  a3
foo.c:75:34: error: 'b1' undeclared (first use in this function); did you mean 'm1'?
   75 |         SetInter(a1, n1, a2, n2, b1, &m1);
      |                                  ^~
      |                                  m1
foo.c:76:34: error: 'b2' undeclared (first use in this function); did you mean 'm2'?
   76 |         SetInter(a1, n1, a3, n3, b2, &m2);
      |                                  ^~
      |                                  m2
foo.c:85:9: error: expected declaration or statement at end of input
   85 |         }
      |         ^
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
A10-4 集合的交集
比赛
2023 程序设计与竞赛(作业5:从数组看集体)
语言
C
递交时间
2023-10-21 22:34:58
评测时间
2023-10-21 22:34:58
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes