记录详情

Compile Error

/in/foo.c: In function 'main':
/in/foo.c:6:19: error: 'n' undeclared (first use in this function)
    6 |         char name[n];
      |                   ^
/in/foo.c:6:19: note: each undeclared identifier is reported only once for each function it appears in
/in/foo.c:9:25: error: expected ';' before 'for'
    9 |         scanf("%d\n",&n)
      |                         ^
      |                         ;
   10 |         for(int i=0;i<n;i++){
      |         ~~~              
/in/foo.c:18:17: error: 'b' undeclared (first use in this function)
   18 |                 b+=student[i].score[j];
      |                 ^
/in/foo.c:19:17: error: 'a' undeclared (first use in this function)
   19 |                 a=b/5;
      |                 ^
/in/foo.c:8:18: warning: unused variable 'student' [-Wunused-variable]
    8 |                 }student[n];
      |                  ^~~~~~~

信息

递交者
类型
自测
语言
C
递交时间
2025-12-24 11:20:13
评测时间
2025-12-24 11:20:13
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes