并查集
我妈嫌我太懒惰
这个作者很懒,什么都没留下…
展开
-
hdu-1232 畅通工程
畅通工程 Problem Description 某省调查城镇交通状况,得到现有城镇道路统计表,表中列出了每条道路直接连通的城镇。省政府“畅通工程”的目标是使全省任何两个城镇间都可以实现交通(但不一定有直接的道路相连,只要互相间接通过道路可达即可)。问最少还需要建设多少条道路? Input 测试输入包含若干测试用例。每个测试用例的第1行给出两个正整数原创 2014-02-25 11:08:21 · 461 阅读 · 0 评论 -
zoj-2833 friendship
A - Friendship Time Limit:3000MS Memory Limit:32768KB 64bit IO Format:%lld & %llu SubmitStatus Description A friend is like a flower, a rose to be exact, Or maybe like a bran原创 2014-02-25 15:27:41 · 612 阅读 · 0 评论 -
hdu-1856 More is better
C - More is better Time Limit:1000MS Memory Limit:102400KB 64bit IO Format:%I64d & %I64u SubmitStatus Description Mr Wang wants some boys to help him with a project. Because the pr原创 2014-02-25 19:21:49 · 438 阅读 · 0 评论 -
poj-2524 Ubiquitous Religions
E - Ubiquitous Religions Time Limit:5000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u SubmitStatus Description There are so many different religions in the world today that原创 2014-02-25 19:58:48 · 432 阅读 · 0 评论