Borderou de evaluare (job #821879)

Utilizator avatar tudor_12 Tudor Bogdan tudor_12 IP ascuns
Problemă Șoricel (clasa a 6-a) Compilator cpp-32
Rundă Arhiva de probleme Status evaluat
Dată 30 apr. 2025 16:57:59 Scor 0

Raport evaluator

Eroare de compilare: main.cpp:11:18: error: conflicting declaration 'int m [201][201]' 11 | int a[201][201], m[201][201]; | ^ main.cpp:9:11: note: previous declaration as 'int m' 9 | int p, n, m, k, cam_max = 0, zile_max = 0, lin, col, val_max = 0, dif = 1, total, numar = 1, cons = 0, suma = 0; | ^ main.cpp: In function 'int main()': main.cpp:47:23: error: 'cons_max' was not declared in this scope 47 | cons = 0; cons_max = 0; | ^~~~~~~~ main.cpp:117:34: error: invalid types 'int[int]' for array subscript 117 | m[lin][col] = zile; | ^ main.cpp:136:34: error: invalid types 'int[int]' for array subscript 136 | m[lin][col] = zile; | ^ main.cpp:158:29: error: invalid types 'int[int]' for array subscript 158 | if(m[lin][col] == numar) | ^ main.cpp:165:32: error: 'cons_max' was not declared in this scope 165 | if(cons_max < cons) | ^~~~~~~~ main.cpp:165:29: warning: this 'if' clause does not guard... [-Wmisleading-indentation] 165 | if(cons_max < cons) | ^~ main.cpp:166:50: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if' 166 | cons_max = cons; zile_max = numar; | ^~~~~~~~ main.cpp:175:29: error: invalid types 'int[int]' for array subscript 175 | if(m[lin][col] == numar) | ^ main.cpp:181:32: error: 'cons_max' was not declared in this scope 181 | if(cons_max < cons) | ^~~~~~~~ main.cpp:181:29: warning: this 'if' clause does not guard... [-Wmisleading-indentation] 181 | if(cons_max < cons) | ^~ main.cpp:182:50: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if' 182 | cons_max = cons; zile_max = numar; | ^~~~~~~~ main.cpp:183:29: error: 'else' without a previous 'if' 183 | else if | ^~~~ main.cpp:184:29: error: expected '(' before 'cons' 184 | cons = 0; | ^~~~ | (