race.cpp:1:24: error: expected constructor, destructor, or type conversion before '(' token
1 | process(v, u, depth + 1, sum + w, filling, c);
| ^
race.cpp:2:13: error: expected declaration before '}' token
2 | }
| ^
race.cpp:3:9: error: expected declaration before '}' token
3 | }
| ^
race.cpp:4:5: error: expected declaration before '}' token
4 | }
| ^
race.cpp: In function 'void build(int, int)':
race.cpp:7:17: error: 'dfs' was not declared in this scope
7 | int n = dfs(u, p);
| ^~~
race.cpp:9:9: error: 'par' was not declared in this scope
9 | par[c] = p;
| ^~~
race.cpp:10:9: error: 'rem' was not declared in this scope
10 | rem[c] = true;
| ^~~
race.cpp:11:9: error: 'mp' was not declared in this scope; did you mean 'p'?
11 | mp[0] = {0, c};
| ^~
| p
race.cpp:12:28: error: 'tree' was not declared in this scope
12 | for (auto [v, w] : tree[c]) {
| ^~~~
race.cpp:14:17: error: 'process' was not declared in this scope
14 | process(v, c, 1, w, 0, c);
| ^~~~~~~
race.cpp:18:28: error: 'tree' was not declared in this scope
18 | for (auto [v, w] : tree[c]) {
| ^~~~
race.cpp: At global scope:
race.cpp:24:1: error: expected unqualified-id before 'public'
24 | public:
| ^~~~~~
race.cpp: In function 'int solve()':
race.cpp:35:16: error: 'ans' was not declared in this scope
35 | return ans;
| ^~~
race.cpp: At global scope:
race.cpp:37:1: error: expected declaration before '}' token
37 | };
| ^
race.cpp: In function 'int best_path(int, int, int (*)[2], int*)':
race.cpp:44:5: error: 'vector' was not declared in this scope
44 | vector<edge> E(n - 1);
| ^~~~~~
race.cpp:44:16: error: expected primary-expression before '>' token
44 | vector<edge> E(n - 1);
| ^
race.cpp:44:18: error: 'E' was not declared in this scope
44 | vector<edge> E(n - 1);
| ^
race.cpp:53:19: error: 'pair' was not declared in this scope
53 | vector<vector<pair<int, long long>>> t(n);
| ^~~~
race.cpp:53:24: error: expected primary-expression before 'int'
53 | vector<vector<pair<int, long long>>> t(n);
| ^~~
race.cpp:55:9: error: 't' was not declared in this scope
55 | t[e.u].push_back({e.v, e.w});
| ^
race.cpp:58:5: error: 'CD' was not declared in this scope
58 | CD g(t, k);
| ^~
race.cpp:59:12: error: 'g' was not declared in this scope
59 | return g.solve();
| ^