Borderou de evaluare (job #613177)
| Utilizator |
|
IP | ascuns |
|---|---|---|---|
| Problemă | John (clasa a 6-a) | Compilator | cpp-32 |
| Rundă | Arhiva de probleme | Status | evaluat |
| Dată | 29 oct. 2021 14:53:25 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'int main()':
main.cpp:6:17: warning: unused variable 'fout' [-Wunused-variable]
6 | FILE *fin, *fout;
| ^~~~
main.cpp:7:23: warning: variable 'p2' set but not used [-Wunused-but-set-variable]
7 | int cer,n,i,d,rez,p2,x;
| ^~
main.cpp: At global scope:
main.cpp:46:5: error: 'fout' does not name a type
46 | fout=fopen("jhon.out", "w");
| ^~~~
main.cpp:47:12: error: expected constructor, destructor, or type conversion before '(' token
47 | fprintf(fout, "%d", rez);
| ^
main.cpp:48:11: error: expected constructor, destructor, or type conversion before '(' token
48 | fclose(fout);
| ^
main.cpp:49:5: error: expected unqualified-id before 'return'
49 | return 0;
| ^~~~~~
main.cpp:50:1: error: expected declaration before '}' token
50 | }
| ^
main.cpp: In function 'int main()':
main.cpp:9:11: warning: ignoring return value of 'int fscanf(FILE*, const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
9 | fscanf(fin, "%d%d", &cer, &n);
| ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~