dreaming.cpp: In function 'void dfs(int, long long int, int)':
dreaming.cpp:10:10: error: 'D' was not declared in this scope
10 | if (d > D) {I = x,D = d;}
| ^
dreaming.cpp:10:14: error: 'I' was not declared in this scope
10 | if (d > D) {I = x,D = d;}
| ^
dreaming.cpp:11:17: error: 'v' was not declared in this scope
11 | for (int j=0;j<v[x].size();j++){
| ^
dreaming.cpp:14:14: error: 'w' was not declared in this scope
14 | dfs(to,d + w,x);
| ^
dreaming.cpp: In function 'long long int upd(long long int, long long int)':
dreaming.cpp:18:26: error: 'l' was not declared in this scope
18 | ll d_new = min(max(d1 + l,d2),max(d1,d2 + l));
| ^
dreaming.cpp:19:2: error: 'diameter' was not declared in this scope
19 | diameter = max(diameter,d1 + l + d2);
| ^~~~~~~~
dreaming.cpp: In function 'int P(int)':
dreaming.cpp:24:11: error: 'p' was not declared in this scope
24 | if (x == p[x]) return x;
| ^
dreaming.cpp:25:9: error: 'p' was not declared in this scope
25 | return p[x] = P(p[x]);
| ^
dreaming.cpp: In function 'void dsu(int, int)':
dreaming.cpp:31:2: error: 'p' was not declared in this scope; did you mean 'vp'?
31 | p[vp] = up;
| ^
| vp
dreaming.cpp: In function 'int travelTime(int, int, int, int*, int*, int*)':
dreaming.cpp:34:2: error: 'l' was not declared in this scope
34 | l = L;
| ^
dreaming.cpp:36:3: error: 'p' was not declared in this scope
36 | p[i] = i,v[i].clear(),d[i] = 1e9;
| ^
dreaming.cpp:36:12: error: 'v' was not declared in this scope
36 | p[i] = i,v[i].clear(),d[i] = 1e9;
| ^
dreaming.cpp:36:25: error: 'd' was not declared in this scope
36 | p[i] = i,v[i].clear(),d[i] = 1e9;
| ^
dreaming.cpp:39:3: error: 'v' was not declared in this scope
39 | v[A[i]].pb({B[i],T[i]});
| ^
dreaming.cpp:45:3: error: 'p' was not declared in this scope
45 | p[i] = P(i);
| ^
dreaming.cpp:46:3: error: 'D' was not declared in this scope
46 | D = 0;
| ^
dreaming.cpp:48:3: error: 'd' was not declared in this scope
48 | d[p[i]] = min(d[p[i]],D);
| ^
dreaming.cpp:49:8: error: 'fix' was not declared in this scope
49 | if (!fix[p[i]]) fix[p[i]] = 1,vec.pb(p[i]);
| ^~~
dreaming.cpp:49:33: error: 'vec' was not declared in this scope
49 | if (!fix[p[i]]) fix[p[i]] = 1,vec.pb(p[i]);
| ^~~
dreaming.cpp:52:2: error: 'D' was not declared in this scope
52 | D = 0;
| ^
dreaming.cpp:53:6: error: 'vec' was not declared in this scope
53 | dfs(vec[0],0,vec[0]);
| ^~~
dreaming.cpp:55:6: error: 'I' was not declared in this scope
55 | dfs(I,0,I);
| ^
dreaming.cpp:56:2: error: 'diameter' was not declared in this scope
56 | diameter = D;
| ^~~~~~~~
dreaming.cpp:59:3: error: 'd' was not declared in this scope
59 | d[vec[i]] = upd(d[vec[i - 1]],d[vec[i]]);
| ^