0_0_38829257_2249.cpp:18:7: error: conflicting declaration 'int Q'
18 | int n,Q;
| ^
0_0_38829257_2249.cpp:16:11: note: previous declaration as 'const int Q'
16 | const int Q=2e5+25;
| ^
0_0_38829257_2249.cpp: In member function 'bool LCT::isroot(int)':
0_0_38829257_2249.cpp:27:34: error: no matching function for call to 'LCT::init(int)'
27 | bool isroot(int i) { init(0); return i!=ch[fa[i]][0] && i!=ch[fa[i]][1]; }
| ~~~~^~~
0_0_38829257_2249.cpp:25:14: note: candidate: 'void LCT::init(int, int)'
25 | void init(int i,int it) { ch[i][0]=ch[i][1]=fa[i]=rev[i]=siz[i]=val[i]=0; id[i]=it; }
| ^~~~
0_0_38829257_2249.cpp:25:14: note: candidate expects 2 arguments, 1 provided
0_0_38829257_2249.cpp: In member function 'bool LCT::cmp(int, int)':
0_0_38829257_2249.cpp:29:45: error: 'u' was not declared in this scope
29 | bool cmp(int x,int y) { return ( ed[u].w<ed[v].w )^fbi; }
| ^
0_0_38829257_2249.cpp:29:53: error: 'v' was not declared in this scope
29 | bool cmp(int x,int y) { return ( ed[u].w<ed[v].w )^fbi; }
| ^
0_0_38829257_2249.cpp: In member function 'void LCT::pushdown(int)':
0_0_38829257_2249.cpp:38:29: error: continue statement not within a loop
38 | if(!rev[x]) continue;
| ^~~~~~~~
0_0_38829257_2249.cpp: In member function 'void LCT::rotate(int)':
0_0_38829257_2249.cpp:49:45: error: invalid types 'int[int]' for array subscript
49 | ch[y][cx]=ch[x][cx^1]; fa[x][cx^1]=y;
| ^
0_0_38829257_2249.cpp: In member function 'void LCT::splay(int)':
0_0_38829257_2249.cpp:55:101: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
55 | for(int i=fa[x];i=fa[x],!isroot(x);rotate(x)) if(!isroot(i)) rotate( getch(i)==getch[x] ? i : x );
| ^
0_0_38829257_2249.cpp: In member function 'void LCT::cut(int, int)':
0_0_38829257_2249.cpp:62:62: error: 'y' was not declared in this scope
62 | void cut(int u,int v) { split(u,v); splay(v); if( ch[y][0]==x&&!ch[x][1] ) ch[y][0]=fa[x]=0; }
| ^
0_0_38829257_2249.cpp:62:69: error: 'x' was not declared in this scope
62 | void cut(int u,int v) { split(u,v); splay(v); if( ch[y][0]==x&&!ch[x][1] ) ch[y][0]=fa[x]=0; }
| ^
0_0_38829257_2249.cpp: In member function 'void BIT::dx(int, int)':
0_0_38829257_2249.cpp:73:52: error: 'lowbit' was not declared in this scope; did you mean 'loebit'?
73 | void dx(int x,int y) { for(int i=x;i<=n;i+=lowbit(i)) c[x]+=y; }
| ^~~~~~
| loebit
0_0_38829257_2249.cpp: In member function 'void BIT::qh(int)':
0_0_38829257_2249.cpp:74:54: error: 'lowbit' was not declared in this scope; did you mean 'loebit'?
74 | void qh(int x) { int ans=0; for(int i=x;i;i-=lowbit(i)) ans+=c[x]; return ans; }
| ^~~~~~
| loebit
0_0_38829257_2249.cpp:74:83: error: return-statement with a value, in function returning 'void' [-fpermissive]
74 | void qh(int x) { int ans=0; for(int i=x;i;i-=lowbit(i)) ans+=c[x]; return ans; }
| ^~~
0_0_38829257_2249.cpp: In function 'void addmi(int, int, int, int)':
0_0_38829257_2249.cpp:85:21: error: 'ldtmi' was not declared in this scope; did you mean 'lctmi'?
85 | if( ldtmi.cmp( mxid,it ) ) {
| ^~~~~
| lctmi
0_0_38829257_2249.cpp: In function 'int main()':
0_0_38829257_2249.cpp:98:28: error: assignment of read-only variable 'Q'
98 | n=read(); Q=read();
| ~^~~~~~~
0_0_38829257_2249.cpp:99:23: error: decrement of read-only variable 'Q'
99 | while(Q--) {
| ^
0_0_38829257_2249.cpp:104:44: error: 'i' was not declared in this scope
104 | ed[i]=(node) { u,v,w };
| ^
0_0_38829257_2249.cpp:104:48: error: 'node' was not declared in this scope; did you mean 'Node'?
104 | ed[i]=(node) { u,v,w };
| ^~~~
| Node
|