模板
#include <bits/stdc++.h>
using namespace std;
using ll=long long;
int main(){
ios::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
return 0;
}
并查集板子
int find(int x) {
return fa[x] == x ? x : fa[x] = find(fa[x]);
}
void unite(int x, int y) {
int fx = find(x), fy = find(y);
if (fx != fy) fa[fx] = fy;
}树状数组板子
int lowbit(int x) {
return x & -x;
}//lowbit函数
int getsum(int x) {
int ans = 0;
while (x > 0) {
ans = ans + c[x];
x = x - lowbit(x);
}
return ans;
}//前缀查询
void add(int x, int k) {
while (x <= n) {
c[x] = c[x] + k;
x = x + lowbit(x);
}
}//单点修改喵喵喵喵喵喵喵喵喵