Borderou de evaluare (job #617752)

Utilizator avatar obrijan.filip Obrijan Filip obrijan.filip IP ascuns
Problemă Căutare binară Compilator cpp-32
Rundă Arhiva de probleme Status evaluat
Dată 24 nov. 2021 12:11:49 Scor 0

Raport evaluator

Eroare de compilare: main.cpp:7:1: error: 'ifstream' does not name a type 7 | ifstream in("cautbin.in"); | ^~~~~~~~ main.cpp:8:1: error: 'ofstream' does not name a type 8 | ofstream out("cautbin.out"); | ^~~~~~~~ main.cpp: In function 'int bsearch1(int, int, int)': main.cpp:29:12: warning: unused variable 'n' [-Wunused-variable] 29 | int m, n = u; | ^ main.cpp: In function 'int main()': main.cpp:67:5: error: 'cin' was not declared in this scope 67 | cin>>n; | ^~~ main.cpp:4:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'? 3 | #include <stdlib.h> +++ |+#include <iostream> 4 | #define N 100010 main.cpp:77:11: error: 'in' was not declared in this scope; did you mean 'n'? 77 | in>>tip>>val; | ^~ | n main.cpp:80:14: error: 'cout' was not declared in this scope 80 | cout<<bsearch0(1,n,val); | ^~~~ main.cpp:80:14: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'? main.cpp:83:14: error: 'cout' was not declared in this scope 83 | cout<<bsearch1(1,n,val); | ^~~~ main.cpp:83:14: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'? main.cpp:86:14: error: 'cout' was not declared in this scope 86 | cout<<bsearch2(1,n,val); | ^~~~ main.cpp:86:14: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'? main.cpp:65:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result] 65 | freopen("cautbin.in","r",stdin); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ main.cpp:66:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result] 66 | freopen("cautbin.out","w",stdout); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~