记录详情

Compile Error

foo.c:1:9: error: #include expects "FILENAME" or <FILENAME>
    1 | #include
      |         ^
foo.c:2:6: warning: return type of 'main' is not 'int' [-Wmain]
    2 | void main()
      |      ^~~~
foo.c: In function 'main':
foo.c:5:1: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    5 | printf("请输入年份:");
      | ^~~~~~
foo.c:5:1: warning: incompatible implicit declaration of built-in function 'printf'
foo.c:1:1: note: include '<stdio.h>' or provide a declaration of 'printf'
  +++ |+#include <stdio.h>
    1 | #include
foo.c:6:1: warning: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    6 | scanf("%d",&year);
      | ^~~~~
foo.c:6:1: warning: incompatible implicit declaration of built-in function 'scanf'
foo.c:6:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
比赛
C语言课程设计考试
语言
C
递交时间
2022-05-31 11:07:18
评测时间
2022-05-31 11:07:18
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes