2017年1月15日

线段树 扫描线 HDU 1828

摘要: #include #include #include #include using namespace std; #define inf 100000000 #define MAXN 5010 #define MAXN 20010 struct edge { int l,r,h,f; //线段的 左边 右边 高度 }x[MAXN>1; Build(l,mid,a>1;... 阅读全文

posted @ 2017-01-15 15:34 HelloWorld!--By-MJY 阅读(145) 评论(0) 推荐(0) 编辑

线段树扫描线 HDU 1542

摘要: n个矩形 问他们覆盖的面积重复的就算一次 x数组存线段 然后根据横坐标排一下 z 线段树 l - r 就是1 ~ 2*n 阅读全文

posted @ 2017-01-15 10:42 HelloWorld!--By-MJY 阅读(125) 评论(0) 推荐(0) 编辑

导航