记录详情

Compile Error

foo.c: In function 'Output':
foo.c:5:20: error: expected ';' before '}' token
    5 |   printf("%d",a[i])
      |                    ^
      |                    ;
    6 | }
      | ~                   
foo.c: In function 'main':
foo.c:13:10: warning: passing argument 1 of 'Output' makes pointer from integer without a cast [-Wint-conversion]
   13 |  Output(a[9999],n);
      |         ~^~~~~~
      |          |
      |          int
foo.c:2:17: note: expected 'int *' but argument is of type 'int'
    2 | void Output(int a[],int x)
      |             ~~~~^~~
foo.c:10:2: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
   10 |  scanf("%d",&n);
      |  ^~~~~~~~~~~~~~
foo.c:12:3: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
   12 |   scanf("%d",&a[i]);
      |   ^~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
A7-1 数组的输出函数
比赛
2022春 C语言课程设计 作业2
语言
C
递交时间
2022-03-19 20:47:04
评测时间
2022-03-19 20:47:04
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes