Borderou de evaluare (job #807501)

Utilizator avatar Crimz0n25 Stefan Tanas Crimz0n25 IP ascuns
Problemă Punga (clasa a 7-a) Compilator cpp-32
Rundă Arhiva de probleme Status evaluat
Dată 1 feb. 2025 20:01:29 Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:2:10: error: 'ifstream' is not a member of 'std' 2 | std::ifstream fin("punga.in"); | ^~~~~~~~ main.cpp:1:1: note: 'std::ifstream' is defined in header '<fstream>'; this is probably fixable by adding '#include <fstream>' +++ |+#include <fstream> 1 | int main() { main.cpp:3:10: error: 'ofstream' is not a member of 'std' 3 | std::ofstream fout("punga.out"); | ^~~~~~~~ main.cpp:3:10: note: 'std::ofstream' is defined in header '<fstream>'; this is probably fixable by adding '#include <fstream>' main.cpp:6:5: error: 'fin' was not declared in this scope 6 | fin >> T; | ^~~ main.cpp:7:10: error: 'vector' is not a member of 'std' 7 | std::vector<ull> K(T); | ^~~~~~ main.cpp:1:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>' +++ |+#include <vector> 1 | int main() { main.cpp:7:17: error: 'ull' was not declared in this scope 7 | std::vector<ull> K(T); | ^~~ main.cpp:7:22: error: 'K' was not declared in this scope 7 | std::vector<ull> K(T); | ^ main.cpp:16:12: error: expected ';' before 'K_i' 16 | ull K_i = K[t]; | ^~~~ | ; main.cpp:17:12: error: expected ';' before 's_low' 17 | ull s_low = 2; | ^~~~~~ | ; main.cpp:18:12: error: expected ';' before 's_high' 18 | ull s_high = 2 * ((ull)1e9); // Suma maxima posibila | ^~~~~~~ | ; main.cpp:19:12: error: expected ';' before 'best_s' 19 | ull best_s = 0, best_w = 0, best_h = 0; | ^~~~~~~ | ; main.cpp:21:16: error: 's_low' was not declared in this scope 21 | while (s_low <= s_high) { | ^~~~~ main.cpp:21:25: error: 's_high' was not declared in this scope 21 | while (s_low <= s_high) { | ^~~~~~ main.cpp:22:16: error: expected ';' before 's_mid' 22 | ull s_mid = s_low + (s_high - s_low) / 2;