Borderou de evaluare (job #1011876)
Utilizator | Data | 17 octombrie 2013 18:14:37 | |
---|---|---|---|
Problema | Algoritmul Bellman-Ford | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘void bellman()’:
user.cpp:42:24: error: no matching function for call to ‘std::queue<int>::push(pereche)’
Q.push(pereche(1,0));
^
user.cpp:42:24: note: candidates are:
In file included from /usr/local/include/c++/4.8.0/queue:64:0,
from user.cpp:3:
/usr/local/include/c++/4.8.0/bits/stl_queue.h:212:7: note: void std::queue<_Tp, _Sequence>::push(const value_type&) [with _Tp = int; _Sequence = std::deque<int, std::allocator<int> >; std::queue<_Tp, _Sequence>::value_type = int]
push(const value_type& __x)
^
/usr/local/include/c++/4.8.0/bits/stl_queue.h:212:7: note: no known conversion for argument 1 from ‘pereche’ to ‘const value_type& {aka const int&}’
/usr/local/include/c++/4.8.0/bits/stl_queue.h:217:7: note: void std::queue<_Tp, _Sequence>::push(std::queue<_Tp, _Sequence>::value_type&&) [with _Tp = int; _Sequence = std::deque<int, std::allocator<int> >; std::queue<_Tp, _Sequence>::value_type = int]
push(value_type&& __x)
^
/usr/local/include/c++/4.8.0/bits/stl_queue.h:217:7: note: no known conversion for argument 1 from ‘pereche’ to ‘std::queue<int>::value_type&& {aka int&&}’
user.cpp:54:20: error: no match for ‘operator[]’ (operand types are ‘int [50100]’ and ‘pereche’)
if(dmin[*it]>cst+it->b) {
^
user.cpp:57:54: error: no matching function for call to ‘std::queue<int>::push(pereche)’
Q.push(pereche(it->a,dmin[it->a]));
^
user.cpp:57:54: note: candidates are:
In file included from /usr/local/include/c++/4.8.0/queue:64:0,
from user.cpp:3:
/usr/local/include/c++/4.8.0/bits/stl_queue.h:212:7: note: void std::queue<_Tp, _Sequence>::push(const value_type&) [with _Tp = int; _Sequence = std::deque<int, std::allocator<int> >; std::queue<_Tp, _Sequence>::value_type = int]
push(const value_type& __x)
^
/usr/local/include/c++/4.8.0/bits/stl_queue.h:212:7: note: no known conversion for argument 1 from ‘pereche’ to ‘const value_type& {aka const int&}’
/usr/local/include/c++/4.8.0/bits/stl_queue.h:217:7: note: void std::queue<_Tp, _Sequence>::push(std::queue<_Tp, _Sequence>::value_type&&) [with _Tp = int; _Sequence = std::deque<int, std::allocator<int> >; std::queue<_Tp, _Sequence>::value_type = int]
push(value_type&& __x)
^
/usr/local/include/c++/4.8.0/bits/stl_queue.h:217:7: note: no known conversion for argument 1 from ‘pereche’ to ‘std::queue<int>::value_type&& {aka int&&}’
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !