![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
线段树&&数组数组
life4711
这个作者很懒,什么都没留下…
展开
-
hdu 5147 树状数组
http://acm.hdu.edu.cn/showproblem.php?pid=5147Problem DescriptionLong long ago, there is a sequence A with length n. All numbers in this sequence is no smaller than 1 and no bigger than n, a原创 2014-12-21 17:30:32 · 1012 阅读 · 0 评论 -
hdu 4893 2014多校联合第三场 1007 线段树
http://acm.hdu.edu.cn/showproblem.php?pid=4893原创 2014-07-30 21:21:52 · 664 阅读 · 0 评论 -
线段树及其基本操作
下图是对线段[1,10)建立的一棵线段树基本结构1.每个节点都是一个[a,b)的区间,根节点代表了整个所要处理的区间2. 对于每个非叶节点[a,b),令mid = (a + b) / 2;则其左右儿子节点代表的区间为[a,mid),[mid,b)3.二叉的组织结构4. 线段树是一个平衡树,树的高度为logN5. 线段树把区间上的任意一条长度为L的线段都分成不超过原创 2014-06-01 16:49:22 · 2851 阅读 · 3 评论 -
hdu4417 树状数组(求指定区间比指定数小的数的个数)
http://acm.hdu.edu.cn/showproblem.php?pid=4417Problem DescriptionMario is world-famous plumber. His “burly” figure and amazing jumping ability reminded in our memory. Now the poor princess i原创 2015-04-05 11:54:45 · 2467 阅读 · 0 评论 -
codeforce 6E 线段树+枚举
http://codeforces.com/problemset/problem/6/E原创 2014-06-02 10:31:30 · 1073 阅读 · 0 评论 -
hdu4267分组线段树
http://acm.hdu.edu.cn/showproblem.php?pid=4267Problem DescriptionLet A1, A2, ... , AN be N elements. You need to deal with two kinds of operations. One type of operation is to add a give原创 2015-03-21 09:30:10 · 928 阅读 · 0 评论 -
CF19D 线段树+STL各种应用
http://codeforces.com/problemset/problem/19/DDescriptionPete and Bob invented a new interesting game. Bob takes a sheet of paper and locates a Cartesian coordinate system on it as follows:原创 2015-01-07 22:31:30 · 1575 阅读 · 0 评论 -
poj 3468 区间更新 整个区间加一个数和区间求和操作
http://poj.org/problem?id=3468原创 2014-08-01 20:07:47 · 1610 阅读 · 0 评论 -
hdu1698 线段树 区间更新
http://acm.hdu.edu.cn/showproblem.php?pid=1698原创 2014-08-01 11:34:04 · 706 阅读 · 0 评论 -
hdu4288 离线处理线段树
http://acm.hdu.edu.cn/showproblem.php?pid=4288Problem Description In mathematics and computer science, an algorithm describes a set of procedures or instructions that define a procedure原创 2015-04-06 21:33:36 · 852 阅读 · 0 评论 -
2014多校第四场1006 HDU 4902 Nice boat 线段树 区间更新问题
http://acm.hdu.edu.cn/showproblem.php?pid=4902原创 2014-08-06 15:10:58 · 664 阅读 · 0 评论 -
hdu5195 线段树
http://acm.hdu.edu.cn/showproblem.php?pid=5195Problem DescriptionA topological sort or topological ordering of a directed graph is a linear ordering of its vertices such that for every d原创 2015-03-31 10:47:43 · 975 阅读 · 0 评论 -
hdu 4747 线段树
http://acm.hdu.edu.cn/showproblem.php?pid=4747Problem DescriptionMex is a function on a set of integers, which is universally used for impartial game theorem. For a non-negative integer set原创 2015-04-16 21:31:41 · 884 阅读 · 0 评论 -
light oj 1080 线段树和树状数组
http://www.lightoj.com/volume_showproblem.php?problem=1080原创 2014-08-10 15:55:15 · 726 阅读 · 0 评论 -
poj 2777 线段树区间更新
http://poj.org/problem?id=2777原创 2014-08-02 15:12:12 · 559 阅读 · 0 评论 -
hdu 1166 敌兵布阵 线段树
Problem DescriptionC国的死对头A国这段时间正在进行军事演习,所以C国间谍头子Derek和他手下Tidy又开始忙乎了。A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任务就是要监视这些工兵营地的活动情况。由于采取了某种先进的监测手段,所以每个工兵营地的人数C国都掌握的一清二楚,每个工兵营地的人数都有可能发生变动,可能增加或减少若干人手,但这些都逃不过C国的监视原创 2014-06-01 16:52:30 · 588 阅读 · 0 评论 -
hdu 2665 可持久化线段树求区间第K大值(函数式线段树||主席树)
http://acm.hdu.edu.cn/showproblem.php?pid=2665Problem DescriptionGive you a sequence and ask you the kth big number of a inteval. InputThe first line is the number of the t原创 2015-04-24 11:39:23 · 1684 阅读 · 0 评论 -
hdu 4339 multiset 或 线段树
http://acm.hdu.edu.cn/showproblem.php?pid=4339Problem DescriptionYou are given two strings s1[0..l1], s2[0..l2] and Q - number of queries.Your task is to answer next queries: 1) 1 a i c原创 2015-02-03 12:50:17 · 806 阅读 · 0 评论 -
hdu 3973 字符串hash+线段树
http://acm.hdu.edu.cn/showproblem.php?pid=3973Problem DescriptionYou are given some words {Wi}. Then our stupid AC will give you a very long string S. AC is stupid and always wants to know w原创 2014-12-29 19:34:32 · 1210 阅读 · 0 评论 -
AC dreamoj 1011 树状数组+hash维护字符串的前缀和
http://acdream.info/problem?pid=1019Problem DescriptionNow we have a long long string, and we will have two kinds of operation on it.C i y : change the ith letter to y.Q i j : check whet原创 2014-12-26 16:12:13 · 934 阅读 · 0 评论 -
2014广州网络赛1002||hdu5023 线段树&&状态压缩
http://acm.hdu.edu.cn/showproblem.php?pid=5023原创 2014-09-22 09:46:20 · 741 阅读 · 0 评论 -
2014多校联合第9场1011题||hdu 4970 树状数组
http://acm.hdu.edu.cn/showproblem.php?pid=4970Problem DescriptionKingdom Rush is a popular TD game, in which you should build some towers to protect your kingdom from monsters. And now anoth原创 2014-08-19 17:47:26 · 768 阅读 · 0 评论 -
NEERC 2015 Southern Subregional G Hiring 树状数组
http://codeforces.com/contest/589/problem/GG. Hiringtime limit per test4 secondsmemory limit per test512 megabytesinputstandard inputoutputstandard outp原创 2015-10-23 11:41:59 · 728 阅读 · 0 评论