#4071
CicluL
Se dă lista muchiilor unui graf neorientat cu n
vârfuri și un număr L
. Să se determine un ciclu elementar de lungime L
.
Problema | CicluL | Operații I/O |
ciclul.in /ciclul.out
|
---|---|---|---|
Limita timp | 0.5 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #40379668 | Utilizator | |
Fișier | ciclul.cpp | Dimensiune | 846 B |
Data încărcării | 07 Decembrie 2022, 11:58 | Scor / rezultat | Eroare de compilare |
ciclul.cpp:1:9: error: #include expects "FILENAME" or <FILENAME> #include ^ ciclul.cpp:2:9: error: #include expects "FILENAME" or <FILENAME> #include ^ ciclul.cpp:4:1: error: 'ifstream' does not name a type ifstream fin("lantq.in"); ^ ciclul.cpp:5:1: error: 'ofstream' does not name a type ofstream fout("lantq.out"); ^ ciclul.cpp: In function 'void read()': ciclul.cpp:10:3: error: 'fin' was not declared in this scope fin>>n>>m; ^ ciclul.cpp: In function 'void write(int)': ciclul.cpp:23:5: error: 'fout' was not declared in this scope fout<<x<<' '; ^ ciclul.cpp:24:3: error: 'fout' was not declared in this scope fout<<'\n'; ^ ciclul.cpp: In function 'void back(int)': ciclul.cpp:30:11: warning: the address of 'viz' will always evaluate as 'true' [-Waddress] if(!viz &&a[x[k-1]]) ^ ciclul.cpp:32:12: error: incompatible types in assignment of 'int' to 'int [21]' viz=1; ^ ciclul.cpp:37:12: error: incompatible types in assignment of 'int' to 'int [21]' viz=0; ^ ciclul.cpp: In function 'int main()': ciclul.cpp:42:14: error: 'fout' was not declared in this scope if(!gr[q]) fout<<"NU EXISTA"; ^ ciclul.cpp:48:12: error: incompatible types in assignment of 'int' to 'int [21]' viz=1; ^ ciclul.cpp:51:12: error: incompatible types in assignment of 'int' to 'int [21]' viz=0; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema CicluL face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.