觉得浮夸了四年,漠然发现原来是浮躁了四年!

随笔分类 -  贪心

摘要:hdu 2037 今年暑假不AC (http://acm.hdu.edu.cn/showproblem.php?pid=2037)比较经典的贪心问题之一,以结束时间排序,如果下一个时间的开始时间大于等于上一个事件结束时间,那么结果就加一。View Code 1 #include<iostream> 2 #include<cstring> 3 #include<cstdio> 4 #include<algorithm> 5 using namespace std; 6 struct node 7 { 8 int start; 9 int end;1 阅读全文
posted @ 2013-05-03 09:33 heat nan 阅读(341) 评论(0) 推荐(0) 编辑
摘要:B. Taxitime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputAfter the lessons n groups of schoolchildren went outside and decided to visit Polycarpus to celebrate his birthday. We know that the i-th group consists of si friends (1 ≤ si ≤ 4), and they 阅读全文
posted @ 2013-03-02 12:19 heat nan 阅读(259) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示