Borderou de evaluare (job #617797)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Căutare binară | Compilator | cpp-32 |
Rundă | Arhiva de probleme | Status | evaluat |
Dată | 24 nov. 2021 13:36:45 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:4:1: error: 'ifstream' does not name a type
4 | ifstream in("cautbin.in");
| ^~~~~~~~
main.cpp:5:1: error: 'ofstream' does not name a type
5 | ofstream out("cautbin.out");
| ^~~~~~~~
main.cpp: In function 'int bsearch1(int, int, int)':
main.cpp:27:12: warning: unused variable 'n' [-Wunused-variable]
27 | int m, n = u;
| ^
main.cpp: In function 'int main()':
main.cpp:63:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
63 | freopen("cautbin.in","r",stdin);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:64:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
64 | freopen("cautbin.out","w",stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:65:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
65 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
main.cpp:67:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
67 | scanf("%d", &v[i]);
| ~~~~~^~~~~~~~~~~~~
main.cpp:69:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
69 | scanf("%d", &m);
| ~~~~~^~~~~~~~~~
main.cpp:72:16: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
72 | scanf("%d%d", &tip, &val);
| ~~~~~^~~~~~~~~~~~~~~~~~~~