Benzinas

Taškai: 0

Compile: FAIL

benzinas.cpp: In function ‘std::vector<long long int> dijkstra(int, std::vector<std::vector<std::pair<int, long long int> > >&, std::vector<int>&)’: benzinas.cpp:12:63: error: wrong number of template arguments (0, should be 1) 12 | priority_queue<pair<ll,int>, vector<pair<ll,int>>, greater<>> pq; | ^ In file included from /usr/include/c++/11/string:48, from /usr/include/c++/11/bits/locale_classes.h:40, from /usr/include/c++/11/bits/ios_base.h:41, from /usr/include/c++/11/ios:42, from /usr/include/c++/11/istream:38, from /usr/include/c++/11/sstream:38, from /usr/include/c++/11/complex:45, from /usr/include/c++/11/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54, from benzinas.cpp:1: /usr/include/c++/11/bits/stl_function.h:385:12: note: provided for ‘template<class _Tp> struct std::greater’ 385 | struct greater : public binary_function<_Tp, _Tp, bool> | ^~~~~~~ benzinas.cpp:12:64: error: template argument 3 is invalid 12 | priority_queue<pair<ll,int>, vector<pair<ll,int>>, greater<>> pq; | ^~ benzinas.cpp:15:8: error: request for member ‘push’ in ‘pq’, which is of non-class type ‘int’ 15 | pq.push({0, start}); | ^~~~ benzinas.cpp:18:16: error: request for member ‘empty’ in ‘pq’, which is of non-class type ‘int’ 18 | while (!pq.empty()) { | ^~~~~ benzinas.cpp:19:14: warning: structured bindings only available with ‘-std=c++17’ or ‘-std=gnu++17’ 19 | auto [d, v] = pq.top(); pq.pop(); | ^ benzinas.cpp:19:26: error: request for member ‘top’ in ‘pq’, which is of non-class type ‘int’ 19 | auto [d, v] = pq.top(); pq.pop(); | ^~~ benzinas.cpp:19:36: error: request for member ‘pop’ in ‘pq’, which is of non-class type ‘int’ 19 | auto [d, v] = pq.top(); pq.pop(); | ^~~ benzinas.cpp:22:19: warning: structured bindings only available with ‘-std=c++17’ or ‘-std=gnu++17’ 22 | for (auto [u, w] : adj[v]) { | ^ benzinas.cpp:26:20: error: request for member ‘push’ in ‘pq’, which is of non-class type ‘int’ 26 | pq.push({dist[u], u}); | ^~~~

nr.resulttimemessage