![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
并查集
fanxingxue
这个作者很懒,什么都没留下…
展开
-
poj 2524 Ubiquitous Religions
题目链接:http://poj.org/problem?id=2524 题目描述: There are so many different religions in the world today that it is difficult to keep track of them all. You are interested in finding out how many diffe...原创 2018-08-29 20:13:34 · 128 阅读 · 0 评论 -
poj 1182 食物链
题目链接:http://poj.org/problem?id=1182 题目描述: 动物王国中有三类动物A,B,C,这三类动物的食物链构成了有趣的环形。A吃B, B吃C,C吃A。 现有N个动物,以1-N编号。每个动物都是A,B,C中的一种,但是我们并不知道它到底是哪一种。 有人用两种说法对这N个动物所构成的食物链关系进行描述: 第一种说法是"1 X Y",表示X和Y是同类。 第二种说法是"2 ...原创 2018-08-29 21:55:02 · 112 阅读 · 0 评论