foo.cc: In function 'int main()':
foo.cc:23:71: warning: format '%f' expects argument of type 'float*', but argument 5 has type 'int*' [-Wformat=]
scanf("%d %s %s %f",&rec[i].id,rec[i].name,rec[i].phone,&rec[i].secs);
~~~~~~~~~~~~^
foo.cc:37:10: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
if(flag=0)
~~~~^~
foo.cc:23:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d %s %s %f",&rec[i].id,rec[i].name,rec[i].phone,&rec[i].secs);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务