foo.c: In function 'main':
foo.c:22:9: warning: format '%s' expects argument of type 'char *', but argument 2 has type 'char (*)[15]' [-Wformat=]
scanf("%s",&stu[i].name);
~^ ~~~~~~~~~~~~
foo.c:28:9: warning: format '%s' expects argument of type 'char *', but argument 2 has type 'char (*)[15]' [-Wformat=]
scanf("%s",&ren);
~^ ~~~~
foo.c:42:1: warning: implicit declaration of function 'system' [-Wimplicit-function-declaration]
system("pause");
^~~~~~
foo.c: In function 'cmp':
foo.c:17:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
foo.c: In function 'main':
foo.c:20:1: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&n);
^~~~~~~~~~~~~~
foo.c:22:1: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%s",&stu[i].name);
^~~~~~~~~~~~~~~~~~~~~~~~
foo.c:28:1: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%s",&ren);
^~~~~~~~~~~~~~~~
foo.c:30:1: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d",&stu[song].money,&stu[song].renshu);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
foo.c:34:1: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%s",ren);
^~~~~~~~~~~~~~~