摘要:
Portal:http://acm.hdu.edu.cn/showproblem.php?pid=1863 依然最小生成树+并查集 因为不保证所有村庄在一个强连通分量里,所以用并查集要判断能否“畅通” 1 #include<iostream> 2 #include<algorithm> 3 #inc 阅读全文
posted @ 2016-07-05 22:39
MukoiAoi
阅读(195)
评论(0)
推荐(0)
摘要:
Portal: http://acm.hdu.edu.cn/showproblem.php?pid=1233 最小生成树模板题 kruskal+并查集 因为给出了所有村庄间的距离,所以保证所有村庄在一个强连通分量里,所以直接kruskal 1 #include<iostream> 2 #includ 阅读全文
posted @ 2016-07-05 22:30
MukoiAoi
阅读(136)
评论(0)
推荐(0)

浙公网安备 33010602011771号