Borderou de evaluare (job #747008)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Cursa Formula 1 (clasa a 5-a) | Compilator | c-32 |
Rundă | Concurs 02 | IQ Academy | clasa a 5-a, seara | Status | evaluat |
Dată | 24 nov. 2023 09:50:05 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.c: In function 'main':
main.c:9:19: error: invalid operands to binary & (have 'char *' and 'int')
9 | scanf(fin,"%d"&n);
| ~~~~^
| |
| char *
main.c:9:11: warning: passing argument 1 of 'scanf' from incompatible pointer type [-Wincompatible-pointer-types]
9 | scanf(fin,"%d"&n);
| ^~~
| |
| FILE *
In file included from main.c:1:
/usr/include/stdio.h:421:42: note: expected 'const char * restrict' but argument is of type 'FILE *'
421 | extern int scanf (const char *__restrict __format, ...) __wur;
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:11:10: warning: statement with no effect [-Wunused-value]
11 | for(i<=n;i++;){
| ~^~~
main.c:13:17: warning: passing argument 1 of 'scanf' from incompatible pointer type [-Wincompatible-pointer-types]
13 | scanf(fin,"%d%d%d%d",&b,&c,&y);
| ^~~
| |
| FILE *
/usr/include/stdio.h:421:42: note: expected 'const char * restrict' but argument is of type 'FILE *'
421 | extern int scanf (const char *__restrict __format, ...) __wur;
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:21:12: warning: passing argument 1 of 'printf' from incompatible pointer type [-Wincompatible-pointer-types]
21 | printf(fout,a," ",m);
| ^~~~
| |
| FILE *
In file included from /usr/include/stdio.h:906:
/usr/include/bits/stdio2.h:84:32: note: expected 'const char * restrict' but argument is of type 'FILE *'
84 | printf (const char *__restrict __fmt, ...)
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~~
main.c:13:11: warning: ignoring return value of 'scanf' declared with attribute 'warn_unused_result' [-Wunused-result]
13 | scanf(fin,"%d%d%d%d",&b,&c,&y);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~