Borderou de evaluare (job #617798)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Căutare binară | Compilator | cpp-32 |
Rundă | Arhiva de probleme | Status | evaluat |
Dată | 24 nov. 2021 13:37:45 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:6:2: error: 'ifstream' does not name a type
6 | ifstream in("cautbin.in");
| ^~~~~~~~
main.cpp:7:1: error: 'ofstream' does not name a type
7 | 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:62:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
62 | freopen("cautbin.in","r",stdin);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
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.out","w",stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:64:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
64 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
main.cpp:66:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
66 | scanf("%d", &v[i]);
| ~~~~~^~~~~~~~~~~~~
main.cpp:68:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
68 | scanf("%d", &m);
| ~~~~~^~~~~~~~~~
main.cpp:71:16: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
71 | scanf("%d%d", &tip, &val);
| ~~~~~^~~~~~~~~~~~~~~~~~~~