Borderou de evaluare (job #2621847)

Utilizator BulaceanuAlexandraBulaceanu Alexandra-Irina BulaceanuAlexandra Data 30 mai 2020 21:02:20
Problema Cautare binara Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:10:1: error: 'fin' does not name a type fin>>n; ^~~ main.cpp:12:7: error: 'n' was not declared in this scope int v[n]; ^ main.cpp: In function 'int cautareBinara0(int, int, int)': main.cpp:23:13: error: 'v' was not declared in this scope if (v[mid] <= val) ^ main.cpp:35:9: error: 'v' was not declared in this scope if (v[mid] > val) mid --; ^ main.cpp:37:9: error: 'v' was not declared in this scope if (v[mid] == val) ^ main.cpp: In function 'int cautareBinara1(int, int, int)': main.cpp:54:13: error: 'v' was not declared in this scope if (v[mid] <= val) ^ main.cpp:66:9: error: 'v' was not declared in this scope if (v[mid] > val) ^ main.cpp: In function 'int cautareBinara2(int, int, int)': main.cpp:84:13: error: 'v' was not declared in this scope if (v[mid] < val) ^ main.cpp:96:9: error: 'v' was not declared in this scope if (v[mid] < val) ^ main.cpp: In function 'int main()': main.cpp:109:26: error: 'n' was not declared in this scope for (int i = 1; i <= n; ++ i) ^ main.cpp:110:14: error: 'v' was not declared in this scope fin>>v[i]; ^ main.cpp:119:37: error: 'n' was not declared in this scope fout<<cautareBinara0(1,n,x)<<endl; ^ main.cpp:123:37: error: 'n' was not declared in this scope fout<<cautareBinara1(1,n,x)<<endl; ^ main.cpp:127:37: error: 'n' was not declared in this scope fout<<cautareBinara2(1,n,x)<<endl; ^ Non zero exit status: 1

Ceva nu functioneaza?