Borderou de evaluare (job #594764)

Utilizator avatar Zluca.jmecher Zamfir Luca Cristian Zluca.jmecher IP ascuns
Problemă Alarma (clasa a 6-a) Compilator c-32
Rundă Pregătire OSEPI 2 - clasa a 6-a Status evaluat
Dată 5 apr. 2021 19:00:23 Scor 94

Raport evaluator

Compilare: main.c: In function 'main': main.c:13:10: warning: variable 'c' set but not used [-Wunused-but-set-variable] 13 | char c; | ^ main.c:16:9: warning: ignoring return value of 'fscanf' declared with attribute 'warn_unused_result' [-Wunused-result] 16 | fscanf(fin,"%d%d",&mat[i][1],&mat[i][2]); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ main.c:20:13: warning: iteration 3 invokes undefined behavior [-Waggressive-loop-optimizations] 20 | v[i]=fgetc(fin); | ~~~~^~~~~~~~~~~ main.c:19:5: note: within this loop 19 | for(i=1; i<=4; i++) | ^~~ main.c:22:25: warning: array subscript 4 is above array bounds of 'char[4]' [-Warray-bounds] 22 | min=(v[3]-'0')*10+(v[4]-'0'); | ~^~~ main.c:6:6: note: while referencing 'v' 6 | char v[4]; | ^ main.c:47:90: warning: array subscript 2 is above array bounds of 'int[2]' [-Warray-bounds] 47 | lung1=abs(mat[combora[i]/10][1]-mat[combora[i]%10][1])+abs(mat[combora[i]/10][2]-mat[combora[i]%10][2]); | ~~~~~~~~~~~~~~~~~~^~~ main.c:47:112: warning: array subscript 2 is above array bounds of 'int[2]' [-Warray-bounds] 47 | lung1=abs(mat[combora[i]/10][1]-mat[combora[i]%10][1])+abs(mat[combora[i]/10][2]-mat[combora[i]%10][2]); | ~~~~~~~~~~~~~~~~~~^~~ main.c:48:112: warning: array subscript 2 is above array bounds of 'int[2]' [-Warray-bounds] 48 | lung2=abs(mat[combora[i]%10][1]-mat[combmin[j]/10][1])+abs(mat[combora[i]%10][2]-mat[combmin[j]/10][2]); | ~~~~~~~~~~~~~~~~~~^~~ main.c:49:112: warning: array subscript 2 is above array bounds of 'int[2]' [-Warray-bounds] 49 | lung3=abs(mat[combmin[j]/10][1]-mat[combmin[j]%10][1])+abs(mat[combmin[j]/10][2]-mat[combmin[j]%10][2]); | ~~~~~~~~~~~~~~~~~~^~~
Test Timp execuție Memorie folosită Mesaj Punctaj/test
1 1 ms 262 kb OK 10
2 1 ms 262 kb OK 10
3 1 ms 262 kb OK 10
4 1 ms 262 kb OK 10
5 1 ms 262 kb OK 10
6 1 ms 262 kb OK 10
7 1 ms 262 kb OK 10
8 1 ms 262 kb a) OK; b) rezultat incorect 4
9 1 ms 262 kb OK 10
10 1 ms 262 kb OK 10
Punctaj total 94