摘要: Problem DescriptionSome of the secret doors contain a very interesting word puzzle. The team of archaeologists has to solve it to open that doors. Because there is no other way to open the doors, the puzzle is very important for us.There is a large number of magnetic plates on every door. Every plat 阅读全文
posted @ 2013-08-11 19:50 默默如潮 阅读(241) 评论(0) 推荐(0) 编辑
摘要: 并查集是一种很方便实现也很有效的数据结构,应用也十分的广泛,主要包括两个操作,合并与查询,当然还有很多的变形。一、先来很裸的并查集:uva1160 - X-PlosivesX-PlosivesA secret service developed a new kind of explosive that attain its volatile property only when a specific association of products occurs. Each product is a mix of two different simple compounds, to which 阅读全文
posted @ 2013-08-11 10:37 默默如潮 阅读(437) 评论(0) 推荐(0) 编辑