Borderou de evaluare (job #800159)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Cifre (clasa a 5-a) | Compilator | c-32 |
Rundă | Arhiva de probleme | Status | evaluat |
Dată | 17 dec. 2024 19:01:21 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.c: In function 'main':
main.c:6:14: error: too few arguments to function 'fopen'
6 | FILE*fin=fopen("cifre.in");
| ^~~~~
In file included from main.c:1:
/usr/include/stdio.h:264:14: note: declared here
264 | extern FILE *fopen (const char *__restrict __filename,
| ^~~~~
main.c:18:18: error: expected ';' before '}' token
18 | a=a/100
| ^
| ;
19 | }
| ~
main.c:20:17: error: too few arguments to function 'fopen'
20 | FILE*fout=fopen("cifre.out");
| ^~~~~
/usr/include/stdio.h:264:14: note: declared here
264 | extern FILE *fopen (const char *__restrict __filename,
| ^~~~~
main.c:21:22: warning: format '%d' expects argument of type 'int', but argument 3 has type 'int *' [-Wformat=]
21 | fprintf(fout,"%d ",&da);
| ~^ ~~~
| | |
| int int *
| %n
main.c:25:12: error: 'fout' undeclared (first use in this function)
25 | fclose(fout);
| ^~~~
main.c:25:12: note: each undeclared identifier is reported only once for each function it appears in
main.c:9:9: warning: ignoring return value of 'fscanf' declared with attribute 'warn_unused_result' [-Wunused-result]
9 | fscanf(fin,"%d",&a);
| ^~~~~~~~~~~~~~~~~~~