Borderou de evaluare (job #2948137)

Utilizator Andreeamiruna27Mindrescu Andreea Andreeamiruna27 Data 27 noiembrie 2022 12:20:14
Problema Ciclu Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:12:15: error: conflicting declaration 'int f [1002]' 12 | int viz[DIM], f[DIM], c[1000000]; | ^ main.cpp:7:10: note: previous declaration as 'std::ifstream f' 7 | ifstream f("ciclu.in"); | ^ main.cpp: In function 'int bellmanFord(long long int, int)': main.cpp:20:19: error: no match for 'operator[]' (operand types are 'std::ifstream' {aka 'std::basic_ifstream<char>'} and 'int') 20 | viz[i] = f[i] = 0; | ^ main.cpp:45:22: error: no match for 'operator[]' (operand types are 'std::ifstream' {aka 'std::basic_ifstream<char>'} and 'int') 45 | f[vecin]++; | ^ main.cpp:46:25: error: no match for 'operator[]' (operand types are 'std::ifstream' {aka 'std::basic_ifstream<char>'} and 'int') 46 | if(f[vecin]>n) | ^ Non zero exit status: 1

Ceva nu functioneaza?