摘要: 简单的贪心:代码:View Code #include <cstdio>#include <set>#include <algorithm>#include <cstring>using namespace std;#define N 100005struct st{ int d,p;}num[N];multiset<int> v;int fan(struct st A,struct st B){ if(A.p < B.p ||(A.p == B.p && A.d < B.d)) return 1; ret 阅读全文
posted @ 2013-04-02 20:20 fly_lovelove 阅读(198) 评论(0) 推荐(0) 编辑
摘要: 问题描述Death-Moon loves telling stories. Some days ago, he told us a funny story. Long long ago, there is a hamster who is so naughty. Now, he comes to a place likes a N * N square. so, he is so excited to drill holes underground. 输入Input until EOF. Fisrt input two integers N (3 <= N < 100) and M 阅读全文
posted @ 2013-04-02 11:42 fly_lovelove 阅读(213) 评论(0) 推荐(0) 编辑