![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
树状数组
文章平均质量分 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 · 636 阅读 · 0 评论 -
牛客练习赛22 E 简单数据结构1(拓展欧拉定理+树状数组)
题目解析:首先了解欧拉定理1 欧拉定理2再是欧拉线性筛线性筛最后是拓展欧拉定理还有小的知识是树状数组的区间更新+单点查询 链接上官方题解先线性筛phi然后考虑用拓展欧拉定理降幂(这里a的指数部分应该是)我们发现对一个数取欧拉函数,log次就会变成1,而任何数模1肯定=0,所以就可以算出来了。然而这么做还会有一些小问题。首先我们发现后面的p...原创 2018-07-24 13:26:43 · 409 阅读 · 0 评论 -
Educational Codeforces Round 53 (Rated for Div. 2) D - Berland Fair
D. Berland Fairtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputXXI Berland Annual Fair is coming really soon! Traditionally fair...原创 2018-10-27 12:11:31 · 322 阅读 · 0 评论 -
ZOJ 2112 Dynamic Rankings(带修改的主席树)
Dynamic RankingsDynamic RankingsTime Limit: 10 Seconds Memory Limit: 32768 KBThe 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 · 232 阅读 · 0 评论