![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
并查集
crella___
当你还不能写出自己满意的程序时,你就不要去睡觉。
展开
-
偏移向量并查集——A Bug's Life
**Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite ge原创 2017-02-17 10:46:50 · 284 阅读 · 0 评论 -
并查集向量偏移
http://blog.csdn.net/u010660276/article/details/24851367原创 2017-02-17 00:34:35 · 247 阅读 · 0 评论 -
HDU - 1198
Benny has a spacious farm land to irrigate. The farm land is a rectangle, and is divided into a lot of samll squares. Water pipes are placed in these squares. Different square has a different type of p原创 2017-02-18 15:53:20 · 297 阅读 · 0 评论 -
并查集—Virtual Friends
**These days, you can do all sorts of things online. For example, you can use various websites to make virtual friends. For some people, growing their social network (their friends, their friends’ frie原创 2017-02-15 20:50:57 · 343 阅读 · 0 评论 -
Uva 1664 Conquer a New Region (Kruskal化用)
该题巧妙的运用了并查集,运用了类似于最小生成树算法的过程 ,通过该题可以对并查集有一个更深的理解 。 题目:由于i和j唯一通路上容量的最小值为该两点的容量,求一个点到其他所有点的容量最大值 。显然题目叙述与MST相似。问题是在合并集合时,中心城市的选择。首先,解决两点的容量问题 ,我们将所有边从大到小排序,然后从大到小枚举,我们假设根结点就是要找的城市中心点,那么当又加入一条边时,该边的两个顶点所在原创 2017-04-06 12:58:27 · 398 阅读 · 0 评论