Borderou de evaluare (job #2814045)

Utilizator oporanu.alexAlex Oporanu oporanu.alex Data 7 decembrie 2021 14:50:35
Problema Diametrul unui arbore Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 30

Raport evaluator

Compilare: main.cpp: In function 'int main()': main.cpp:34:12: warning: unused variable 'E' [-Wunused-variable] 34 | int V, E; | ^ main.cpp:31:17: warning: iteration 104 invokes undefined behavior [-Waggressive-loop-optimizations] 31 | dist[i] = -1; | ~~~~~~~~^~~~ main.cpp:30:22: note: within this loop 30 | for(int i = 1; i <= nmax; ++i) | ~~^~~~~~~ main.cpp:44:17: warning: iteration 104 invokes undefined behavior [-Waggressive-loop-optimizations] 44 | dist[i] = -1; | ~~~~~~~~^~~~ main.cpp:43:22: note: within this loop 43 | for(int i = 1; i <= nmax; ++i) | ~~^~~~~~~ main.cpp:31:17: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset [420, 423] is out of the bounds [0, 420] of object 'dist' with type 'int [105]' [-Warray-bounds] 31 | dist[i] = -1; | ~~~~~~~~^~~~ main.cpp:6:5: note: 'dist' declared here 6 | int dist[nmax] = {-1}; | ^~~~ main.cpp:44:17: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset [420, 423] is out of the bounds [0, 420] of object 'dist' with type 'int [105]' [-Warray-bounds] 44 | dist[i] = -1; | ~~~~~~~~^~~~ main.cpp:6:5: note: 'dist' declared here 6 | int dist[nmax] = {-1}; | ^~~~
Test Timp executie Memorie folosita Mesaj Punctaj/test
12ms184kbOK10
22ms200kbOK10
32ms184kbOK10
42ms184kbKilled by Signal 110
52ms184kbKilled by Signal 110
62ms184kbKilled by Signal 110
72ms184kbKilled by Signal 110
82ms184kbKilled by Signal 110
92ms184kbKilled by Signal 110
102ms184kbKilled by Signal 110
Punctaj total30

Ceva nu functioneaza?