#548
Hamilton
Se dă un graf neorientat cu n
vârfuri. Determinați, dacă există, un ciclu hamiltonian.
Problema | Hamilton | Operații I/O |
hamilton.in /hamilton.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #54241195 | Utilizator | |
Fișier | hamilton.cpp | Dimensiune | 1020 B |
Data încărcării | 23 Noiembrie 2024, 10:32 | Scor / rezultat | Eroare de compilare |
hamilton.cpp:12:13: warning: missing terminating " character [enabled by default] fout << "1 ^ hamilton.cpp:12:5: error: missing terminating " character fout << "1 ^ hamilton.cpp:13:1: warning: missing terminating " character [enabled by default] "; ^ hamilton.cpp:13:1: error: missing terminating " character hamilton.cpp:16:21: warning: missing terminating " character [enabled by default] fout << x[1] << " ^ hamilton.cpp:16:5: error: missing terminating " character fout << x[1] << " ^ hamilton.cpp:17:1: warning: missing terminating " character [enabled by default] "; ^ hamilton.cpp:17:1: error: missing terminating " character hamilton.cpp: In function 'void afis(int)': hamilton.cpp:14:5: error: expected primary-expression before 'for' for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:14:5: error: expected ';' before 'for' hamilton.cpp:14:22: error: 'i' was not declared in this scope for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:14:35: error: expected ';' before ')' token for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:18:11: error: no match for 'operator=' (operand types are 'std::basic_ostream<char>' and 'int') gasit = 1; ^ hamilton.cpp:18:11: note: candidate is: In file included from /usr/include/c++/4.8/istream:39:0, from /usr/include/c++/4.8/fstream:38, from hamilton.cpp:1: /usr/include/c++/4.8/ostream:58:11: note: std::basic_ostream<char>& std::basic_ostream<char>::operator=(const std::basic_ostream<char>&) <deleted> class basic_ostream : virtual public basic_ios<_CharT, _Traits> ^ /usr/include/c++/4.8/ostream:58:11: note: no known conversion for argument 1 from 'int' to 'const std::basic_ostream<char>&'
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Hamilton 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ă.