Wrong Answer

foo.cc: In function 'int main()':
foo.cc:37:30: warning: format '%d' expects argument of type 'int', but argument 5 has type 'double' [-Wformat=]
   37 |       printf("%-8d%-8s%-8c%-8d\n",s[i].num,s[i].name,s[i].sex? 'M':'F',s[i].score);
      |                           ~~~^                                         ~~~~~~~~~~
      |                              |                                              |
      |                              int                                            double
      |                           %-8f
foo.cc:21:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   21 |  {  scanf("%d %s %d %f",&s[i].num,s[i].name,&s[i].sex,&s[i].score);
      |     ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Wrong Answer Read 4, expect 99. 2ms 384.0 KiB

信息

递交者
类型
递交
题目
P1151 结构体-学生信息处理3
语言
C++
递交时间
2022-04-01 10:18:21
评测时间
2022-04-01 10:18:21
评测机
分数
0
总耗时
2ms
峰值内存
384.0 KiB