摘要: 解析 由于数据太大了, \(10^9\) 的内存绝对会炸, 所以要用离散化 Code #include <bits/stdc++.h> using namespace std; int n, m, z, x, y; int f[10005]; int find (int x) { while (x 阅读全文
posted @ 2021-07-09 09:13 unknown_future 阅读(53) 评论(0) 推荐(0) 编辑
摘要: 解析 这道题是一道冰茶姬的模板题, 不必多言, 直接上代码 Code #include <bits/stdc++.h> using namespace std; int n, m, z, x, y; int f[10005]; int find (int x) { while (x != f[x]) 阅读全文
posted @ 2021-07-09 07:41 unknown_future 阅读(47) 评论(0) 推荐(0) 编辑