Borderou de evaluare (job #1515795)
Utilizator | Data | 2 noiembrie 2015 10:17:04 | |
---|---|---|---|
Problema | Ubuntzei | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:31:77: error: template argument 2 is invalid
priority_queue < pair < int, int >, vector < pair < int, int >, pqCompare > Q;
^
user.cpp:31:77: error: template argument 3 is invalid
user.cpp: In function ‘void initDijkstra(int)’:
user.cpp:37:5: error: ‘Q’ was not declared in this scope
Q.clear();
^
user.cpp: In function ‘void dijkstra(int)’:
user.cpp:44:12: error: ‘Q’ was not declared in this scope
while(!Q.empty()) {
^
user.cpp:50:25: error: no matching function for call to ‘get(int&)’
v = get<0>(i);
^
user.cpp:50:25: note: candidates are:
In file included from /usr/include/c++/4.8/algorithm:60:0,
from user.cpp:3:
/usr/include/c++/4.8/utility:142:5: note: template<unsigned int _Int, class _Tp1, class _Tp2> constexpr typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type& std::get(std::pair<_Tp1, _Tp2>&)
get(std::pair<_Tp1, _Tp2>& __in) noexcept
^
/usr/include/c++/4.8/utility:142:5: note: template argument deduction/substitution failed:
user.cpp:50:25: note: mismatched types ‘std::pair<_Tp1, _Tp2>’ and ‘int’
v = get<0>(i);
^
In file included from /usr/include/c++/4.8/algorithm:60:0,
from user.cpp:3:
/usr/include/c++/4.8/utility:147:5: note: template<unsigned int _Int, class _Tp1, class _Tp2> constexpr typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&& std::get(std::pair<_Tp1, _Tp2>&&)
get(std::pair<_Tp1, _Tp2>&& __in) noexcept
^
/usr/include/c++/4.8/utility:147:5: note: template argument deduction/substitution failed:
user.cpp:50:25: note: mismatched types ‘std::pair<_Tp1, _Tp2>’ and ‘int’
v = get<0>(i);
^
In file included from /usr/include/c++/4.8/algorithm:60:0,
from user.cpp:3:
/usr/include/c++/4.8/utility:152:5: note: template<unsigned int _Int, class _Tp1, class _Tp2> constexpr const typename std::tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type& std::get(const std::pair<_Tp1, _Tp2>&)
get(const std::pair<_Tp1, _Tp2>& __in) noexcept
^
/usr/include/c++/4.8/utility:152:5: note: template argument deduction/substitution failed:
user.cpp:50:25: note: mismatched types ‘const std::pair<_Tp1, _Tp2>’ and ‘int’
v = get<0>(i);
^
In file included from /usr/include/c++/4.8/tuple:39:0,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/bits/stl_algo.h:66,
from /usr/include/c++/4.8/algorithm:62,
from user.cpp:3:
/usr/include/c++/4.8/array:268:5: note: template<unsigned int _Int, class _Tp, unsigned int _Nm> constexpr _Tp& std::get(std::array<_Tp, _Nm>&)
get(array<_Tp, _Nm>& __arr) noexcept
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !