poj 2761 Feed the dogs(treap+离线)
题目链接:http://poj.org/problem?id=2761
思路:求区间第k小的树,题目中有一个关键的条件即没有一个区间能够包含另外一个区间,也就是说如果[ai,bi],[aj,bj]两个区间如果ai
#include
#include
#include
using namespace std;
const int N=50005;
struct seg
{
int st,
原创
2015-02-20 23:51:16 ·
622 阅读 ·
0 评论