dreaming.cpp: In function 'int travelTime(int, int, int, int*, int*, int*)':
dreaming.cpp:36:32: error: 'c' was not declared in this scope
G[A[i]+1].push_back({B[i]+1, c});
^
dreaming.cpp:36:34: error: no matching function for call to 'std::vector<edge>::push_back(<brace-enclosed initializer list>)'
G[A[i]+1].push_back({B[i]+1, c});
^
In file included from /usr/include/c++/7/vector:64:0,
from /usr/include/c++/7/queue:61,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:86,
from dreaming.cpp:2:
/usr/include/c++/7/bits/stl_vector.h:939:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = edge; _Alloc = std::allocator<edge>; std::vector<_Tp, _Alloc>::value_type = edge]
push_back(const value_type& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:939:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type& {aka const edge&}'
/usr/include/c++/7/bits/stl_vector.h:953:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = edge; _Alloc = std::allocator<edge>; std::vector<_Tp, _Alloc>::value_type = edge]
push_back(value_type&& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:953:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::vector<edge>::value_type&& {aka edge&&}'
dreaming.cpp:37:34: error: no matching function for call to 'std::vector<edge>::push_back(<brace-enclosed initializer list>)'
G[B[i]+1].push_back({A[i]+1, c});
^
In file included from /usr/include/c++/7/vector:64:0,
from /usr/include/c++/7/queue:61,
from /usr/include/x86_64-linux-gnu/c++/7/bits/stdc++.h:86,
from dreaming.cpp:2:
/usr/include/c++/7/bits/stl_vector.h:939:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = edge; _Alloc = std::allocator<edge>; std::vector<_Tp, _Alloc>::value_type = edge]
push_back(const value_type& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:939:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type& {aka const edge&}'
/usr/include/c++/7/bits/stl_vector.h:953:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = edge; _Alloc = std::allocator<edge>; std::vector<_Tp, _Alloc>::value_type = edge]
push_back(value_type&& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:953:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::vector<edge>::value_type&& {aka edge&&}'