摘要: 1Y爽歪歪线段树功能:1. 单点更新 2.查询区间递增子序列长度代码:#include <iostream>#include <stdio.h>#include <string.h>#include <algorithm>using namespace std;#define for if(0); else forconst int N=100010;struct SegNode{int lval... 阅读全文
posted @ 2012-08-06 10:31 编程菜菜 阅读(140) 评论(0) 推荐(0) 编辑
摘要: 线段树经典题线段树功能:1.区间覆盖2.查询区间最长连续1个数代码:#include <iostream>#include <stdio.h>#include <string.h>#include <algorithm>using namespace std;#define for if(0); else forconst int N=65536+10;struct SegNode{int lsu... 阅读全文
posted @ 2012-08-06 09:34 编程菜菜 阅读(168) 评论(0) 推荐(0) 编辑