摘要:
使用 稀疏图求最小生成树边权和 O(mlogm) 模板 Kruskal算法求最小生成树 #include<iostream> #include<algorithm> using namespace std; const int N = 200010; int n,m; int p[N]; //并查集 阅读全文
posted @ 2021-07-27 16:29
Xuuxxi
阅读(35)
评论(0)
推荐(0)
摘要:
用处 求最小生成树的权和时使用 稠密图 O(nm) 模板 Prim算法求最小生成树 #include<iostream> #include<algorithm> #include<cstring> using namespace std; const int N = 510,INF = 0x3f3f 阅读全文
posted @ 2021-07-27 15:30
Xuuxxi
阅读(37)
评论(0)
推荐(0)