![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
树状数组
Twilightuse
这个作者很懒,什么都没留下…
展开
-
hdu 2492 Ping pong
题意: 有n个人要进行乒乓球比赛每一个人都一个技术值,每个人出现的次序就是 他们住的位置,现在要求进行一场比赛,三个人,裁判的技术值在两个人的 中间,位置也在两个人的中间,问一共可以进行这种比赛多少次。原创 2014-08-22 17:08:19 · 423 阅读 · 0 评论 -
poj 3321 Apple Tree题解
http://poj.org/problem?id=3321原创 2014-08-26 15:38:22 · 448 阅读 · 0 评论 -
HDU 4046 Panda(树状数组)
题解: 由于没改一个位置,都会影响后三个的结果,那么后三个都需要跟着改变。 #include #include #define MAX 50109 int c[MAX]; char str[MAX]; int lowbit(int x) { return x&-x; } int sum(int x) { int ret=0; while(x>0) { r原创 2014-11-30 16:02:02 · 391 阅读 · 0 评论