2013年5月13日

Poj 2528 Mayor's posters 线段树 离散化 成段更新

摘要: Mayor's postersTime Limit:1000MSMemory Limit:65536KTotal Submissions:32605Accepted:9469DescriptionThe citizens of Bytetown, AB, could not stand that the candidates in the mayoral election campaign have been placing their electoral posters at all places at their whim. The city council has finally 阅读全文

posted @ 2013-05-13 15:59 电子幼体 阅读(97) 评论(0) 推荐(0) 编辑

二分模板以及STL中的查找

摘要: 二分查找的基本实现int b_search(int key,int a[],int n) { int l=0,r=n-1; while (l=key的第一个元素的位置upper_bound()返回数组中>key的第一个元素的位置-------------------ForwardIterator lower_bound (ForwardIterator first,ForwardIterator last, const T& value)ForwardIterator lower_bound (ForwardIterator first,ForwardIterator last. 阅读全文

posted @ 2013-05-13 15:38 电子幼体 阅读(168) 评论(0) 推荐(0) 编辑

导航