树状数组
文章平均质量分 89
highacm
这个作者很懒,什么都没留下…
展开
-
poj2352Stars(树状数组)
分析:由于输入数据是以y为第一关键递增输入,以x为第二关键字递增输入,因此,可以直接对x用一维树状数组。 #include #include int count[32005]; int c[32005]; int lowbit(int x) { return x&(-x); } void change(int x) { int i; for(i=x;i<32005;i+=lowbit(i)原创 2013-04-16 22:34:38 · 584 阅读 · 0 评论 -
poj1195(二维树状数组)
Mobile phones Time Limit: 5000MS Memory Limit: 65536K Total Submissions: 12189 Accepted: 5590 Description Suppose that the fourth generation mobile phone base stations原创 2013-04-17 12:44:37 · 538 阅读 · 0 评论