摘要: 第一个自己动手写的线段树,1Y还是有点小激动哈(虽然是模版题) 1 #include 2 #include 3 #include 4 using namespace std; 5 const int SIZE=200005; 6 const int INF=1000000; 7 int maxv[SIZE>1;16 build(l,mid,rt=r) return maxv[rt];23 int mid=(l+r)>>1;24 int ret=-INF;25 if(Lmid) ret=max(ret,findmax(L,R,mid+1,r,rt>1;32 ... 阅读全文
posted @ 2014-03-08 21:56 ACalvin 阅读(193) 评论(0) 推荐(0) 编辑