摘要: You are given a sequence a1, a2, ..., an consisting of different integers. It is required to split this sequence into the maximum number of subsequenc 阅读全文
posted @ 2017-08-25 20:14 Wally的博客 阅读(338) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=6178 题目大意: 已知n个节点有n-1条连线,现在有k只猴子,每只猴子必须要住在一个节点上,两只猴子之间最少要有一条连线。问k只猴子最少要有多少条连线。 解题思路: 首先由于数据太大而且要在1s内完成所以应该用输 阅读全文
posted @ 2017-08-25 16:11 Wally的博客 阅读(180) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=6180 题目大意: 已知一些商品制作的开始和结束时间,问在使用最少的机器的前提下机器工作的最少的总时间是多少?? 解题思路: 解法一: 如何求出至少要多少台机器: 把时间段转化成一个入点和一个出点,这样存下2*n个 阅读全文
posted @ 2017-08-25 14:59 Wally的博客 阅读(312) 评论(0) 推荐(0) 编辑