dreaming.cpp: In function 'int travelTime(int, int, int, int*, int*, int*)':
dreaming.cpp:32:5: error: 'unordered_set' was not declared in this scope
32 | unordered_set<int> child_edges[N];
| ^~~~~~~~~~~~~
dreaming.cpp:32:5: note: suggested alternatives:
In file included from /usr/include/c++/13/unordered_set:41,
from dreaming.cpp:5:
/usr/include/c++/13/bits/unordered_set.h:104:11: note: 'std::unordered_set'
104 | class unordered_set
| ^~~~~~~~~~~~~
/usr/include/c++/13/unordered_set:58:13: note: 'std::pmr::unordered_set'
58 | using unordered_set
| ^~~~~~~~~~~~~
dreaming.cpp:32:19: error: expected primary-expression before 'int'
32 | unordered_set<int> child_edges[N];
| ^~~
dreaming.cpp:38:9: error: 'child_edges' was not declared in this scope
38 | child_edges[A[i]].insert(i);
| ^~~~~~~~~~~
dreaming.cpp:45:46: error: 'child_edges' was not declared in this scope
45 | if(components[current_root] != -1 || child_edges[current_root].size() > 1){
| ^~~~~~~~~~~
dreaming.cpp:49:12: error: 'child_edges' was not declared in this scope
49 | if(child_edges[current_root].empty()){
| ^~~~~~~~~~~
dreaming.cpp:57:9: error: 'forward_list' was not declared in this scope
57 | forward_list<int> children = {current_root};
| ^~~~~~~~~~~~
dreaming.cpp:57:9: note: suggested alternatives:
In file included from /usr/include/c++/13/forward_list:40,
from dreaming.cpp:6:
/usr/include/c++/13/bits/forward_list.h:433:11: note: 'std::forward_list'
433 | class forward_list : private _Fwd_list_base<_Tp, _Alloc>
| ^~~~~~~~~~~~
/usr/include/c++/13/forward_list:56:13: note: 'std::pmr::forward_list'
56 | using forward_list = std::forward_list<_Tp, polymorphic_allocator<_Tp>>;
| ^~~~~~~~~~~~
dreaming.cpp:57:22: error: expected primary-expression before 'int'
57 | forward_list<int> children = {current_root};
| ^~~
dreaming.cpp:58:16: error: 'children' was not declared in this scope
58 | while(!children.empty()){
| ^~~~~~~~
dreaming.cpp:62:28: error: 'child_edges' was not declared in this scope
62 | for(int edge : child_edges[child]){
| ^~~~~~~~~~~
dreaming.cpp:79:18: error: 'tuple' was not declared in this scope; did you mean 'std::tuple'?
79 | forward_list<tuple<int, bool> > height_calculation;
| ^~~~~
| std::tuple
In file included from /usr/include/c++/13/bits/stl_algobase.h:64,
from /usr/include/c++/13/vector:62,
from dreaming.cpp:3:
/usr/include/c++/13/bits/stl_pair.h:90:11: note: 'std::tuple' declared here
90 | class tuple;
| ^~~~~
dreaming.cpp:79:5: error: 'forward_list' was not declared in this scope
79 | forward_list<tuple<int, bool> > height_calculation;
| ^~~~~~~~~~~~
dreaming.cpp:79:5: note: suggested alternatives:
/usr/include/c++/13/bits/forward_list.h:433:11: note: 'std::forward_list'
433 | class forward_list : private _Fwd_list_base<_Tp, _Alloc>
| ^~~~~~~~~~~~
/usr/include/c++/13/forward_list:56:13: note: 'std::pmr::forward_list'
56 | using forward_list = std::forward_list<_Tp, polymorphic_allocator<_Tp>>;
| ^~~~~~~~~~~~
dreaming.cpp:79:24: error: expected primary-expression before 'int'
79 | forward_list<tuple<int, bool> > height_calculation;
| ^~~
dreaming.cpp:81:9: error: 'height_calculation' was not declared in this scope
81 | height_calculation.push_front(make_tuple(root_vertices[i], false));
| ^~~~~~~~~~~~~~~~~~
dreaming.cpp:81:39: error: 'make_tuple' was not declared in this scope; did you mean 'std::make_tuple'?
81 | height_calculation.push_front(make_tuple(root_vertices[i], false));
| ^~~~~~~~~~
| std::make_tuple
In file included from /usr/include/c++/13/bits/uses_allocator_args.h:38,
from /usr/include/c++/13/bits/memory_resource.h:41,
from /usr/include/c++/13/vector:80:
/usr/include/c++/13/tuple:2001:5: note: 'std::make_tuple' declared here
2001 | make_tuple(_Elements&&... __args)
| ^~~~~~~~~~
dreaming.cpp:83:12: error: 'height_calculation' was not declared in this scope
83 | while(!height_calculation.empty()){
| ^~~~~~~~~~~~~~~~~~
dreaming.cpp:86:9: error: 'tie' was not declared in this scope; did you mean 'std::tie'?
86 | tie(vertex, status) = height_calculation.front();
| ^~~
| std::tie
/usr/include/c++/13/tuple:2169:5: note: 'std::tie' declared here
2169 | tie(_Elements&... __args) noexcept
| ^~~
dreaming.cpp:89:28: error: 'child_edges' was not declared in this scope
89 | for(int edge : child_edges[vertex]){
| ^~~~~~~~~~~
dreaming.cpp:97:43: error: 'make_tuple' was not declared in this scope; did you mean 'std::make_tuple'?
97 | height_calculation.push_front(make_tuple(vertex, true));
| ^~~~~~~~~~
| std::make_tuple
/usr/include/c++/13/tuple:2001:5: note: 'std::make_tuple' declared here
2001 | make_tuple(_Elements&&... __args)
| ^~~~~~~~~~
dreaming.cpp:98:28: error: 'child_edges' was not declared in this scope
98 | for(int edge : child_edges[vertex]){
| ^~~~~~~~~~~
dreaming.cpp:103:5: error: 'vector' was not declared in this scope
103 | vector<int> max_paths[N - M];
| ^~~~~~
dreaming.cpp:103:5: note: suggested alternatives:
In file included from /usr/include/c++/13/vector:66:
/usr/include/c++/13/bits/stl_vector.h:428:11: note: 'std::vector'
428 | class vector : protected _Vector_base<_Tp, _Alloc>
| ^~~~~~
/usr/include/c++/13/vector:86:13: note: 'std::pmr::vector'
86 | using vector = std::vector<_Tp, polymorphic_allocator<_Tp>>;
| ^~~~~~
dreaming.cpp:103:12: error: expected primary-expression before 'int'
103 | vector<int> max_paths[N - M];
| ^~~
dreaming.cpp:106:9: error: 'max_paths' was not declared in this scope
106 | max_paths[component] = {root};
| ^~~~~~~~~
dreaming.cpp:112:13: error: 'child_edges' was not declared in this scope
112 | child_edges[last_vertex].erase(height_edges[last_vertex]);
| ^~~~~~~~~~~
dreaming.cpp:117:25: error: 'max_paths' was not declared in this scope
117 | int best_upward[max_paths[component].size()];
| ^~~~~~~~~
dreaming.cpp:118:9: error: 'best_upward' was not declared in this scope
118 | best_upward[0] = 0;
| ^~~~~~~~~~~
dreaming.cpp:121:28: error: 'child_edges' was not declared in this scope
121 | for(int edge : child_edges[max_paths[component][i]]){
| ^~~~~~~~~~~
dreaming.cpp:130:18: error: expected primary-expression before 'int'
130 | forward_list<int> eccentricity_calculation;
| ^~~
dreaming.cpp:131:16: error: expected primary-expression before 'int'
131 | for(vector<int> max_path : max_paths){
| ^~~
dreaming.cpp:136:5: error: expected primary-expression before 'while'
136 | while(!eccentricity_calculation.empty()){
| ^~~~~
dreaming.cpp:135:6: error: expected ';' before 'while'
135 | }
| ^
| ;
136 | while(!eccentricity_calculation.empty()){
| ~~~~~
dreaming.cpp:136:5: error: expected primary-expression before 'while'
136 | while(!eccentricity_calculation.empty()){
| ^~~~~
dreaming.cpp:135:6: error: expected ')' before 'while'
135 | }
| ^
| )
136 | while(!eccentricity_calculation.empty()){
| ~~~~~
dreaming.cpp:131:8: note: to match this '('
131 | for(vector<int> max_path : max_paths){
| ^
dreaming.cpp:136:12: error: 'eccentricity_calculation' was not declared in this scope
136 | while(!eccentricity_calculation.empty()){
| ^~~~~~~~~~~~~~~~~~~~~~~~
dreaming.cpp:139:24: error: 'child_edges' was not declared in this scope
139 | for(int edge : child_edges[vertex]){
| ^~~~~~~~~~~