2014年7月28日
摘要: 贪心+优先队列+问题分解对x,y 分开处理当 xl 2 #include 3 #include 4 #include 5 using namespace std; 6 7 struct node { 8 int l,r; 9 int id;10 friend bool... 阅读全文
posted @ 2014-07-28 16:07 gfc 阅读(164) 评论(0) 推荐(0) 编辑
摘要: 每次从最底部开始处理,如果不是最大值,则把最大值翻到底部。这就是最优解。原理自己模拟一下就好。。。注意半径不是从1开始。数据处理要仔细。 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 7 int m... 阅读全文
posted @ 2014-07-28 08:48 gfc 阅读(126) 评论(0) 推荐(0) 编辑