摘要: Let's imagine how apple tree looks in binary computer world. You're right, it looks just like a binary tree, i.e. any biparous branch splits up to exa 阅读全文
posted @ 2019-11-29 20:41 蓉~ 阅读(258) 评论(0) 推荐(0) 编辑
摘要: Whuacmers use coins.They have coins of value A1,A2,A3...An Silverland dollar. One day Hibix opened purse and found there were some coins. He decided t 阅读全文
posted @ 2019-11-27 21:00 蓉~ 阅读(428) 评论(0) 推荐(0) 编辑
摘要: 设有N堆石子排成一排,其编号为1,2,3,…,N。 每堆石子有一定的质量,可以用一个整数来描述,现在要将这N堆石子合并成为一堆。 每次只能合并相邻的两堆,合并的代价为这两堆石子的质量之和,合并后与这两堆石子相邻的石子将和新堆相邻,合并时由于选择的顺序不同,合并的总代价也不相同。 例如有4堆石子分别为 阅读全文
posted @ 2019-11-27 20:02 蓉~ 阅读(161) 评论(0) 推荐(0) 编辑
摘要: Dawn-K recently discovered a very magical phenomenon in the supermarket of Northeastern University: The large package is not necessarily more expensiv 阅读全文
posted @ 2019-11-25 21:01 蓉~ 阅读(183) 评论(0) 推荐(0) 编辑
摘要: Nowadays, a kind of chess game called “Super Jumping! Jumping! Jumping!” is very popular in HDU. Maybe you are a good boy, and know little about this 阅读全文
posted @ 2019-11-25 20:57 蓉~ 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 在双 11 时,心慧精品店有个特别的折价活动如下: 首先,我们定义一个正整数为"好的"当且仅当此数仅由数字 1 构成,举例来说 1, 11, 111, 11111 都是「好的」,但 10、123、321 都是「不好的」。 接着,若一个商品原价为 xx,若顾客能把 xx 表示为 kk 个「好的」数字, 阅读全文
posted @ 2019-11-24 19:29 蓉~ 阅读(149) 评论(0) 推荐(0) 编辑
摘要: Bessie has gone to the mall's jewelry store and spies a charm bracelet. Of course, she'd like to fill it with the best charms possible from the N (1 ≤ 阅读全文
posted @ 2019-11-15 21:06 蓉~ 阅读(201) 评论(0) 推荐(0) 编辑
摘要: Alex doesn't like boredom. That's why whenever he gets bored, he comes up with games. One long winter evening he came up with a game and decided to pl 阅读全文
posted @ 2019-11-14 18:03 蓉~ 阅读(111) 评论(0) 推荐(0) 编辑
摘要: 都说天上不会掉馅饼,但有一天gameboy正走在回家的小径上,忽然天上掉下大把大把的馅饼。说来gameboy的人品实在是太好了,这馅饼别处都不掉,就掉落在他身旁的10米范围内。馅饼如果掉在了地上当然就不能吃了,所以gameboy马上卸下身上的背包去接。但由于小径两侧都不能站人,所以他只能在小径上接。 阅读全文
posted @ 2019-11-14 17:57 蓉~ 阅读(128) 评论(0) 推荐(0) 编辑
摘要: 有n对夫妻被邀请参加一个聚会,因为场地的问题,每对夫妻中只有1人可以列席。在2n 个人中,某些人之间有着很大的矛盾(当然夫妻之间是没有矛盾的),有矛盾的2个人是不会同时出现在聚会上的。有没有可能会有n 个人同时列席? Inputn: 表示有n对夫妻被邀请 (n<= 1000)m: 表示有m 对矛盾关 阅读全文
posted @ 2019-11-07 20:20 蓉~ 阅读(139) 评论(0) 推荐(0) 编辑