| Problema | oop_3 | Operații I/O |
oop_3.in/oop_3.out
|
|---|---|---|---|
| Limita timp | 0.2 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64255125 | Utilizator | |
| Fișier | oop_3.cpp | Dimensiune | 534 B |
| Data încărcării | 26 Aprilie 2026, 14:45 | Scor/rezultat | 50 puncte |
In member function ‘int Stiva::Max()’, inlined from ‘int main()’ at oop_3.cpp:58:32: oop_3.cpp:27:17: warning: array subscript 1 is outside array bounds of ‘void [0]’ [-Warray-bounds=] 27 | int maxim=v[1]; | ^~~~~ In constructor ‘constexpr Stiva::Stiva()’, inlined from ‘int main()’ at oop_3.cpp:43:11: oop_3.cpp:4:7: note: at offset 4 into object of size 0 allocated by ‘operator new []’ 4 | class Stiva | ^~~~~ In file included from /usr/include/c++/13/algorithm:60, from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:51, from oop_3.cpp:1: In function ‘const _Tp& std::max(const _Tp&, const _Tp&) [with _Tp = int]’, inlined from ‘int Stiva::Max()’ at oop_3.cpp:28:47, inlined from ‘int main()’ at oop_3.cpp:58:32: /usr/include/c++/13/bits/stl_algobase.h:262:15: warning: array subscript [2, 2147483647] is outside array bounds of ‘void [0]’ [-Warray-bounds=] 262 | if (__a < __b) | ~~~~^~~~~ In constructor ‘constexpr Stiva::Stiva()’, inlined from ‘int main()’ at oop_3.cpp:43:11: oop_3.cpp:4:7: note: at offset [8, 8589934588] into object of size 0 allocated by ‘operator new []’ 4 | class Stiva | ^~~~~ In member function ‘int Stiva::Top()’, inlined from ‘int main()’ at oop_3.cpp:56:32: oop_3.cpp:21:24: warning: array subscript [1, 2305843009213693951] is outside array bounds of ‘void [0]’ [-Warray-bounds=] 21 | else return v[n]; | ^ In constructor ‘constexpr Stiva::Stiva()’, inlined from ‘int main()’ at oop_3.cpp:43:11: oop_3.cpp:4:7: note: at offset 4 into object of size 0 allocated by ‘operator new []’ 4 | class Stiva | ^~~~~ In member function ‘void Stiva::Push(int)’, inlined from ‘int main()’ at oop_3.cpp:51:19: oop_3.cpp:12:15: warning: array subscript 0 is outside array bounds of ‘void [0]’ [-Warray-bounds=] 12 | v[++n]=x; | ~~~~~~^~ In constructor ‘constexpr Stiva::Stiva()’, inlined from ‘int main()’ at oop_3.cpp:43:11: oop_3.cpp:4:7: note: object of size 0 allocated by ‘operator new []’ 4 | class Stiva | ^~~~~
| Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
|---|---|---|---|---|---|---|
| 1 | 0.001 secunde | OK. | 10 | 10 | Exemplu | |
| 2 | 0.001 secunde | Caught fatal signal 6 | 10 | 0 | ||
| 3 | 0.001 secunde | Caught fatal signal 6 | 10 | 0 | ||
| 4 | 0.002 secunde | OK. | 20 | 20 | ||
| 5 | 0.008 secunde | OK. | 20 | 20 | ||
| 6 | 0.005 secunde | Caught fatal signal 11 | 20 | 0 | ||
| 7 | 0.003 secunde | Caught fatal signal 6 | 10 | 0 | ||
| Punctaj total | 50 | |||||
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema oop_3 face parte din a doua categorie. Pentru aceste probleme se folosește un program suport, furnizat de propunătorul problemei. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.