Borderou de evaluare (job #750730)

Utilizator avatar RobertSerb hacker ^_^ RobertSerb IP ascuns
Problemă Plaja 2 (clasa a 5-a) Compilator c-32
Rundă Arhiva de probleme Status evaluat
Dată 13 dec. 2023 21:00:51 Scor 0

Raport evaluator

Eroare de compilare: main.c: In function 'main': main.c:6:24: error: redeclaration of 'a' with no linkage 6 | int a, b, r, n, x, a; | ^ main.c:6:9: note: previous declaration of 'a' with type 'int' 6 | int a, b, r, n, x, a; | ^ main.c:9:27: error: expected ';' before 'for' 9 | fscanf( fin, "%d", &a) | ^ | ; 10 | for (int i = 2; i <= n; i++) { | ~~~ main.c:6:21: warning: unused variable 'x' [-Wunused-variable] 6 | int a, b, r, n, x, a; | ^ main.c:6:15: warning: unused variable 'r' [-Wunused-variable] 6 | int a, b, r, n, x, a; | ^ main.c:6:12: warning: unused variable 'b' [-Wunused-variable] 6 | int a, b, r, n, x, a; | ^ main.c:8:5: warning: ignoring return value of 'fscanf' declared with attribute 'warn_unused_result' [-Wunused-result] 8 | fscanf( fin, "%d", &n); | ^~~~~~~~~~~~~~~~~~~~~~ main.c:9:5: warning: ignoring return value of 'fscanf' declared with attribute 'warn_unused_result' [-Wunused-result] 9 | fscanf( fin, "%d", &a) | ^~~~~~~~~~~~~~~~~~~~~~