欢迎光临
我们一直在努力

PLCT检查是什么【知识点】LCT

#include<bits/stdc++.h>
#define maxn 100005
#define maxm 500005
#define inf 0x7fffffff
#define ll long long

using namespace std;
int N,M,rc,A[maxn],s[maxn],st[maxn];
int r[maxn],c[maxn][2],f[maxn];

inline int read()

inline bool nroot(int x){return c[f[x]][0]==x||c[f[x]][1]==x;}
inline void pushr(int x){swap(c[x][0],c[x][1]),r[x]^=1;}
inline void pushup(int x){s[x]=s[c[x][0]]^s[c[x][1]]^A[x];}
inline void pushdown(int x)
}
inline void rotate(int x)
inline void splay(int x)
    pushup(x);
}
inline void access(int x){for(int y=0;x;x=f[y=x]) splay(x),c[x][1]=y,pushup(x);}
inline void makeroot(int x){access(x),splay(x),pushr(x);}
inline void split(int x,int y){makeroot(x),access(y),splay(y);}
inline int findroot(int x){
    access(x),splay(x);
    while(c[x][0]) pushdown(x),x=c[x][0];
    splay(x); return x;
}
inline void link(int x,int y)
inline void cut(int x,int y)

int main() 
    return 0;
}
赞(0)
未经允许不得转载:上海聚慕医疗器械有限公司 » PLCT检查是什么【知识点】LCT

登录

找回密码

注册