Borderou de evaluare (job #3174631)
Utilizator | Data | 25 noiembrie 2023 01:51:15 | |
---|---|---|---|
Problema | Rusuoaica | Status | done |
Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In constructor 'Graf::Graf(int, const std::vector<std::tuple<int, int, int> >&)':
main.cpp:14:28: warning: 'Graf::height' will be initialized after [-Wreorder]
14 | std::vector<int> tata, height;
| ^~~~~~
main.cpp:14:22: warning: 'std::vector<int> Graf::tata' [-Wreorder]
14 | std::vector<int> tata, height;
| ^~~~
main.cpp:22:1: warning: when initialized here [-Wreorder]
22 | Graf::Graf(int size, const std::vector<std::tuple<int, int, int>> &m) : n(size), muchii(m), height(std::vector<int>(n, 0)), tata(std::vector<int>(n, 0)){}
| ^~~~
main.cpp: In member function 'int Graf::kruskal(int)':
main.cpp:46:28: error: no matching function for call to 'get<1>(std::tuple<int, int, int>&)'
46 | int u = std::get<1>(m), v = std::get<2>(m), w = std::get<0>(m);
| ~~~~~~~~~~~^~~
In file included from /usr/include/c++/12.2.1/bits/stl_algobase.h:64,
from /usr/include/c++/12.2.1/string:50,
from /usr/include/c++/12.2.1/bits/locale_classes.h:40,
from /usr/include/c++/12.2.1/bits/ios_base.h:41,
from /usr/include/c++/12.2.1/ios:42,
from /usr/include/c++/12.2.1/istream:38,
from /usr/include/c++/12.2.1/fstream:38,
from main.cpp:1:
/usr/include/c++/12.2.1/bits/stl_pair.h:855:5: note: candidate: 'template<long unsigned int _Int, class _Tp1, class _Tp2> constexpr typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type& std::get(pair<_Tp1, _Tp2>&)'
855 | get(pair<_Tp1, _Tp2>& __in) noexcept
| ^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:855:5: note: template argument deduction/substitution failed:
main.cpp:46:28: note: 'std::tuple<int, int, int>' is not derived from 'std::pair<_Tp1, _Tp2>'
46 | int u = std::get<1>(m), v = std::get<2>(m), w = std::get<0>(m);
| ~~~~~~~~~~~^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:860:5: note: candidate: 'template<long unsigned int _Int, class _Tp1, class _Tp2> constexpr typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&& std::get(pair<_Tp1, _Tp2>&&)'
860 | get(pair<_Tp1, _Tp2>&& __in) noexcept
| ^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:860:5: note: template argument deduction/substitution failed:
main.cpp:46:28: note: 'std::tuple<int, int, int>' is not derived from 'std::pair<_Tp1, _Tp2>'
46 | int u = std::get<1>(m), v = std::get<2>(m), w = std::get<0>(m);
| ~~~~~~~~~~~^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:865:5: note: candidate: 'template<long unsigned int _Int, class _Tp1, class _Tp2> constexpr const typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type& std::get(const pair<_Tp1, _Tp2>&)'
865 | get(const pair<_Tp1, _Tp2>& __in) noexcept
| ^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:865:5: note: template argument deduction/substitution failed:
main.cpp:46:28: note: 'std::tuple<int, int, int>' is not derived from 'const std::pair<_Tp1, _Tp2>'
46 | int u = std::get<1>(m), v = std::get<2>(m), w = std::get<0>(m);
| ~~~~~~~~~~~^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:870:5: note: candidate: 'template<long unsigned int _Int, class _Tp1, class _Tp2> constexpr const typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&& std::get(const pair<_Tp1, _Tp2>&&)'
870 | get(const pair<_Tp1, _Tp2>&& __in) noexcept
| ^~~
/usr/include/c++/12.2.1/bits/stl_pair.h:870:5: note: template argument deduction/substitution failed:
main.cpp:46:28: note: 'std::tuple<int, int, int>' is not derived from 'const std::pair<_Tp1, _Tp2>'
46 | int u = std::get<1>(m), v = std::get<2>(m), w = std::get<0>(m);
| ~~~~~~~~~~~^~~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !