#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 | #52559526 | Utilizator | |
Fișier | hamilton.cpp | Dimensiune | 1006 B |
Data încărcării | 03 Octombrie 2024, 10:25 | Scor / rezultat | Eroare de compilare |
hamilton.cpp:11:13: warning: missing terminating " character [enabled by default] fout << "1 ^ hamilton.cpp:11:5: error: missing terminating " character fout << "1 ^ hamilton.cpp:12:1: warning: missing terminating " character [enabled by default] "; ^ hamilton.cpp:12:1: error: missing terminating " character hamilton.cpp:15:21: warning: missing terminating " character [enabled by default] fout << x[1] << " ^ hamilton.cpp:15:5: error: missing terminating " character fout << x[1] << " ^ hamilton.cpp:16:1: warning: missing terminating " character [enabled by default] "; ^ hamilton.cpp:16:1: error: missing terminating " character hamilton.cpp: In function 'void afis(int)': hamilton.cpp:13:5: error: expected primary-expression before 'for' for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:13:5: error: expected ';' before 'for' hamilton.cpp:13:22: error: 'i' was not declared in this scope for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:13:35: error: expected ';' before ')' token for(int i = 1 ; i <= k ; ++ i) ^ hamilton.cpp:17:11: error: no match for 'operator=' (operand types are 'std::basic_ostream<char>' and 'int') gasit = 1; ^ hamilton.cpp:17:11: note: candidate is: In file included from /usr/include/c++/4.8/istream:39:0, from /usr/include/c++/4.8/sstream:38, from /usr/include/c++/4.8/complex:45, from /usr/include/c++/4.8/ccomplex:38, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:52, 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ă.