记录详情

Compile Error

/in/foo.c:1:1: warning: data definition has no type or storage class
    1 | w = float(input())
      | ^
/in/foo.c:1:1: warning: type defaults to 'int' in declaration of 'w' [-Wimplicit-int]
/in/foo.c:1:5: error: expected expression before 'float'
    1 | w = float(input())
      |     ^~~~~
/in/foo.c:3:23: error: stray '#' in program
    3 | total_distance = 0.0  # 累计游泳距离
      |                       ^
/in/foo.c:4:12: error: stray '#' in program
    4 | count = 0  # 游泳次数
      |            ^
/in/foo.c:5:25: error: stray '#' in program
    5 | current_distance = 2.0  # 本次要游的距离,初始为第1下的2米
      |                         ^

信息

递交者
类型
递交
比赛
2025秋季技术通识课编程练习题
语言
C
递交时间
2026-01-12 15:37:31
评测时间
2026-01-12 15:37:31
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes