Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- std::vector<int> dists(G.size(), -1);
- auto pred = [&dists](int a, int b) -> bool {
- return dists[a] > dists[b];
- };
- std::priority_queue<int, std::vector<int>, decltype(pred)> Q;
Advertisement
Add Comment
Please, Sign In to add comment