Borderou de evaluare (job #2986558)

Utilizator Maniu_DianaManiu Maria Diana Maniu_Diana Data 28 februarie 2023 19:26:44
Problema Tastatură defectă Status done
Runda arhiva-utcn Compilator cpp-64 | Vezi sursa
Scor 100

Raport evaluator

Compilare: main.cpp: In function 'int main()': main.cpp:23:13: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare] 23 | while(i <= strlen(s)) | ~~^~~~~~~~~~~~ main.cpp:25:15: warning: array subscript has type 'char' [-Wchar-subscripts] 25 | fr[s[i]] ++; | ~~~^ main.cpp:33:13: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare] 33 | while(i <= strlen(t)) | ~~^~~~~~~~~~~~ main.cpp:35:15: warning: array subscript has type 'char' [-Wchar-subscripts] 35 | fr[t[i]] --; | ~~~^ main.cpp:21:15: warning: iteration 125 invokes undefined behavior [-Waggressive-loop-optimizations] 21 | fr[j] = 0; | ~~~~~~^~~ main.cpp:20:22: note: within this loop 20 | for(int j = 0; j <= 125; j ++) | ~~^~~~~~ main.cpp:21:15: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset [500, 503] is out of the bounds [0, 500] of object 'fr' with type 'int [125]' [-Warray-bounds] 21 | fr[j] = 0; | ~~~~~~^~~ main.cpp:9:5: note: 'fr' declared here 9 | int fr[125]; | ^~
Test Timp executie Memorie folosita Mesaj Punctaj/test
10ms184kbOK100
Punctaj total100

Ceva nu functioneaza?