并查集
One believe
欢迎来到Onebelieve的博客
展开
-
POJ 1417 True Liars(带权并查集+DP)
传送门DescriptionAfter having drifted about in a small boat for a couple of days, Akira Crusoe Maeda was finally cast ashore on a foggy island. Though he was exhausted and despaired, he was still fortu...原创 2020-01-07 21:34:50 · 2298 阅读 · 0 评论 -
POJ 1733 Parity game(带权并查集+离散化)
传送门DescriptionNow and then you play the following game with your friend. Your friend writes down a sequence consisting of zeroes and ones. You choose a continuous subsequence (for example the subseq...原创 2020-01-07 18:07:13 · 182 阅读 · 1 评论 -
POJ 1182食物链(带权并查集)
传送门Description动物王国中有三类动物A,B,C,这三类动物的食物链构成了有趣的环形。A吃B, B吃C,C吃A。现有N个动物,以1-N编号。每个动物都是A,B,C中的一种,但是我们并不知道它到底是哪一种。有人用两种说法对这N个动物所构成的食物链关系进行描述:第一种说法是"1 X Y",表示X和Y是同类。第二种说法是"2 X Y",表示X吃Y。此人对N个动物,用上述两种说法,...原创 2020-01-05 19:18:34 · 133 阅读 · 0 评论 -
HDU 3038 How Many Answers Are Wrong(带权并查集)
Problem DescriptionTT and FF are … friends. Uh… very very good friends -________-bFF is a bad boy, he is always wooing TT to play the following game with him. This is a very humdrum game. To begin w...原创 2020-01-01 20:48:16 · 160 阅读 · 0 评论 -
POJ 2236 Wireless Network(并查集)
传送门DescriptionAn earthquake takes place in Southeast Asia. The ACM (Asia Cooperated Medical team) have set up a wireless network with the lap computers, but an unexpected aftershock attacked, all co...原创 2019-12-07 22:25:35 · 95 阅读 · 0 评论