Borderou de evaluare (job #2702427)
Utilizator | Data | 3 februarie 2021 23:24:23 | |
---|---|---|---|
Problema | Algoritmul lui Dijkstra | Status | done |
Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:20:34: error: 'comparaDistante' was not declared in this scope
priority_queue<int, vector<int>, comparaDistante> Coada;
^~~~~~~~~~~~~~~
main.cpp:20:49: error: template argument 3 is invalid
priority_queue<int, vector<int>, comparaDistante> Coada;
^
main.cpp:23:21: error: 'intx' has not been declared
bool operator()(intx, int y) {
^~~~
main.cpp: In member function 'bool comparaDistante::operator()(int, int)':
main.cpp:24:18: error: 'x' was not declared in this scope
return D[x] > D[y];
^
main.cpp: In function 'void Dijkstra(int)':
main.cpp:42:11: error: request for member 'push' in 'Coada', which is of non-class type 'int'
Coada.push(nodStart);
^~~~
main.cpp:44:19: error: request for member 'empty' in 'Coada', which is of non-class type 'int'
while (!Coada.empty()) {
^~~~~
main.cpp:45:31: error: request for member 'top' in 'Coada', which is of non-class type 'int'
int nodCurent = Coada.top();
^~~
main.cpp:46:15: error: request for member 'pop' in 'Coada', which is of non-class type 'int'
Coada.pop();
^~~
main.cpp:55:27: error: request for member 'push' in 'Coada', which is of non-class type 'int'
Coada.push(Vecin);
^~~~
main.cpp: In function 'int main()':
main.cpp:73:14: error: too few arguments to function 'void Dijkstra(int)'
Dijkstra();
^
main.cpp:37:6: note: declared here
void Dijkstra(int nodStart) {
^~~~~~~~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !