Borderou de evaluare (job #2799043)

Utilizator 134_tufa_liliana_ionelaTufa Liliana Ionela 134_tufa_liliana_ionela Data 12 noiembrie 2021 11:33:43
Problema Parcurgere DFS - componente conexe Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In member function 'void Graf::codBFS(int)': main.cpp:79:13: error: 'g' was not declared in this scope 79 | g<<-1<<' '; | ^ main.cpp:81:13: error: 'g' was not declared in this scope 81 | g<<distanta[i]<<' '; | ^ main.cpp: At global scope: main.cpp:84:34: error: declaration of 'vizitat' as array of references 84 | void Graf::codDFS(int nod, bool &vizitat[]) | ^~~~~~~ main.cpp:84:6: error: no declaration matches 'void Graf::codDFS(...)' 84 | void Graf::codDFS(int nod, bool &vizitat[]) | ^~~~ main.cpp:52:14: note: candidate is: 'void Graf::codDFS(int, bool*)' 52 | void codDFS(int nod, bool vizitat[]); | ^~~~~~ main.cpp:7:7: note: 'class Graf' defined here 7 | class Graf | ^~~~ main.cpp: In member function 'void Graf::ComponenteConexe()': main.cpp:96:12: error: 'vizitat' was not declared in this scope 96 | if(vizitat[i]==false) | ^~~~~~~ main.cpp: In function 'void Dfs()': main.cpp:129:10: warning: unused variable 'vizitat' [-Wunused-variable] 129 | bool vizitat[n+1] = {false}; | ^~~~~~~ main.cpp: In function 'int main()': main.cpp:145:5: error: 'f' was not declared in this scope 145 | f.close(); | ^ main.cpp:146:5: error: 'g' was not declared in this scope 146 | g.close(); | ^ Non zero exit status: 1

Ceva nu functioneaza?