Segment Tree(线段树)
文章平均质量分 90
Chen_yuazzy
The best way to predict the future is to create it.
预测未来的最好办法是去创造它。
---Alan Kay
展开
-
【HDU 1166】排兵布阵(线段树,单点更新)
排兵布阵Description C国的死对头A国这段时间正在进行军事演习,所以C国间谍头子Derek和他手下Tidy又开始忙乎了。A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任务就是要监视这些工兵营地的活动情况。由于采取了某种先进的监测手段,所以每个工兵营地的人数C国都掌握的一清二楚,每个工兵营地的人数都有可能发生变动,可能增加或减少若干人手,但这些都逃不过C国的监视。 中央情报原创 2017-08-12 23:43:35 · 523 阅读 · 0 评论 -
【POJ 2528】Mayor's posters(线段树,离散化)
Mayor’s postersDescription The 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原创 2017-08-20 10:51:24 · 420 阅读 · 0 评论 -
【HDU 1698】Just a Hook(线段树)
Just a HookProblem Description In the game of DotA, Pudge’s meat hook is actually the most horrible thing for most of the heroes. The hook is made up of several consecutive metallic sticks which are o原创 2017-08-20 12:44:58 · 353 阅读 · 0 评论 -
【POJ 3264】Balanced Lineup(RMQ算法||线段树)
Balanced LineupDescriptionFor the daily milking, Farmer John’s N cows (1 ≤ N ≤ 50,000) always line up in the same order. One day Farmer John decides to organize a game of Ultimate Frisbee with some of原创 2017-08-21 16:10:48 · 358 阅读 · 0 评论