2012年6月11日

HDU 1754 线段树裸题

摘要: 水题 #include#define lson l,m,rtmax[rt>1; build(lson); build(rson); Pushup(rt);}int updata(int p,int k,int l,int r,int rt){ int m; if(l... 阅读全文

posted @ 2012-06-11 20:03 DDUPzy 阅读(147) 评论(0) 推荐(0) 编辑

HDU 1166模仿大牛写的线段树

摘要: 裸题 单点更新:最最基础的线段树,只更新叶子节点,然后把信息用PushUP(int r)这个函数更新上来 HDU 1166 十分优美; 上代码 以后多记着 #include#define lson l,m,rt>1; build(lson); build(rson); Pu... 阅读全文

posted @ 2012-06-11 18:27 DDUPzy 阅读(146) 评论(0) 推荐(0) 编辑

【完全版】线段树

摘要: http://www.notonlysuccess.com/index.php/segment-tree-complete/ 阅读全文

posted @ 2012-06-11 17:10 DDUPzy 阅读(118) 评论(0) 推荐(0) 编辑

导航