/in/foo.c: In function 'main':
/in/foo.c:6:17: warning: format '%d' expects argument of type 'int *', but argument 2 has type 'long int *' [-Wformat=]
6 | scanf("%d",&n);
| ~^ ~~
| | |
| | long int *
| int *
| %ld
/in/foo.c:7:36: warning: format '%s' expects argument of type 'char *', but argument 2 has type 'char (*)[100]' [-Wformat=]
7 | for (i=1;i<=n;i++) scanf("%s%d%d%c%c%c%c%d",&name[i],&grade[i],&app[i],&leader[i],&leader[i],&west[i],&west[i],&paper[i]);
| ~^ ~~~~~~~~
| | |
| char * char (*)[100]
/in/foo.c:7:38: warning: format '%d' expects argument of type 'int *', but argument 3 has type 'long int *' [-Wformat=]
7 | for (i=1;i<=n;i++) scanf("%s%d%d%c%c%c%c%d",&name[i],&grade[i],&app[i],&leader[i],&leader[i],&west[i],&west[i],&paper[i]);
| ~^ ~~~~~~~~~
| | |
| int * long int *
| %ld
/in/foo.c:7:40: warning: format '%d' expects argument of type 'int *', but argument 4 has type 'long int *' [-Wformat=]
7 | for (i=1;i<=n;i++) scanf("%s%d%d%c%c%c%c%d",&name[i],&grade[i],&app[i],&leader[i],&leader[i],&west[i],&west[i],&paper[i]);
| ~^ ~~~~~~~
| | |
| int * long int *
| %ld
/in/foo.c:7:50: warning: format '%d' expects argument of type 'int *', but argument 9 has type 'long int *' [-Wformat=]
7 | for (i=1;i<=n;i++) scanf("%s%d%d%c%c%c%c%d",&name[i],&grade[i],&app[i],&leader[i],&leader[i],&west[i],&west[i],&paper[i]);
| ~^ ~~~~~~~~~
| | |
| int * long int *
| %ld
/in/foo.c:25:22: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=]
25 | printf("%s\n%d\n%d",name[stu],max,sum);
| ~^ ~~~
| | |
| int long int
| %ld
/in/foo.c:25:26: warning: format '%d' expects argument of type 'int', but argument 4 has type 'long int' [-Wformat=]
25 | printf("%s\n%d\n%d",name[stu],max,sum);
| ~^ ~~~
| | |
| int long int
| %ld
/in/foo.c:4:16: warning: unused variable 'j' [-Wunused-variable]
4 | long i,j,n,grade[10000],app[10000],paper[10000],money[10000],sum,max,stu;
| ^
/in/foo.c:4:78: warning: 'stu' may be used uninitialized [-Wmaybe-uninitialized]
4 | long i,j,n,grade[10000],app[10000],paper[10000],money[10000],sum,max,stu;
| ^~~