随笔分类 -  图论-并查集

摘要:Time Limit: 1000MSMemory Limit: 10000KTotal Submissions: 32909Accepted: 10158DescriptionThe police office in Tadu City decides to say ends to the chaos, as launch actions to root up the TWO gangs in t... 阅读全文
posted @ 2017-07-22 21:44 Pic 阅读(172) 评论(0) 推荐(0)
摘要:More is better Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 327680/102400 K (Java/Others)Total Submission(s): 25168 Accepted Submission(s): 90 阅读全文
posted @ 2016-11-23 17:52 Pic 阅读(342) 评论(0) 推荐(0)
摘要:小希的迷宫 Problem Description 上次Gardon的迷宫城堡小希玩了很久(见Problem B),现在她也想设计一个迷宫让Gardon来走。但是她设计迷宫的思路不一样,首先她认为所有的通道都应该是双向连通的,就是说如果有一个通道连通了房间A和B,那么既可以通过它从房间A走到房间B, 阅读全文
posted @ 2016-11-23 17:38 Pic 阅读(190) 评论(0) 推荐(0)
摘要:食物链 Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 65906 Accepted: 19437 Description 动物王国中有三类动物A,B,C,这三类动物的食物链构成了有趣的环形。A吃B, B吃C,C吃A。 现有N个动 阅读全文
posted @ 2016-11-23 17:33 Pic 阅读(264) 评论(0) 推荐(0)
摘要:Problem Description TT and FF are ... friends. Uh... very very good friends -________-bFF is a bad boy, he is always wooing TT to play the following g 阅读全文
posted @ 2016-11-20 22:33 Pic 阅读(121) 评论(0) 推荐(0)
摘要:1005 题目 Problem Description 省政府“畅通工程”的目标是使全省任何两个村庄间都可以实现公路交通(但不一定有直接的公路相连,只要能间接通过公路可达即可)。现得到城镇道路统计表,表中列出了任意两城镇间修建道路的费用,以及该道路是否已经修通的状态。现请你编写程序,计算出全省畅通需 阅读全文
posted @ 2016-07-07 00:52 Pic 阅读(121) 评论(0) 推荐(0)
摘要:这一道题是看题解过的,实在是太难了。。好难找的规律。。好坑的思路。在我的这个博客里引用http://m.blog.csdn.net/article/details?id=50638393 中的题解思路,这个题解还使用了矩阵快速幂的方法,具体见这个blog 题目 Problem Description 阅读全文
posted @ 2016-05-29 00:25 Pic 阅读(274) 评论(0) 推荐(0)