
树状数组
文章平均质量分 88
Just_JK
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
hihoCoder Week 172 Matrix Sum (二维树状数组)
时间限制:10000ms 单点时限:1000ms 内存限制:256MB 描述 You are given an N × N matrix. At the beginning every element is 0. Write a program supporting 2 operations: 1. Add x y value: Add value to the ele原创 2017-10-19 15:43:54 · 665 阅读 · 0 评论 -
牛客练习赛22 E 简单数据结构1(拓展欧拉定理+树状数组)
题目 解析: 首先了解欧拉定理1 欧拉定理2 再是欧拉线性筛 线性筛 最后是拓展欧拉定理 还有小的知识是树状数组的区间更新+单点查询 链接 上官方题解 先线性筛phi 然后考虑用拓展欧拉定理降幂 (这里a的指数部分应该是) 我们发现对一个数取欧拉函数,log次就会变成1,而任何数模1肯定=0,所以就可以算出来了。 然而这么做还会有一些小问题。 首先我们发现后面的p...原创 2018-07-24 13:26:43 · 445 阅读 · 0 评论 -
Educational Codeforces Round 53 (Rated for Div. 2) D - Berland Fair
D. Berland Fair time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output XXI Berland Annual Fair is coming really soon! Traditionally fair...原创 2018-10-27 12:11:31 · 360 阅读 · 0 评论 -
ZOJ 2112 Dynamic Rankings(带修改的主席树)
Dynamic Rankings Dynamic Rankings Time Limit: 10 Seconds Memory Limit: 32768 KB The Company Dynamic Rankings has developed a new kind of computer that is no longer satisfied with the query l...原创 2018-12-09 16:50:47 · 264 阅读 · 0 评论