### ivplay's blog

By ivplay, 7 years ago,

This post is only for newbies. A very common trick with Cumulative Sum + BIT is discussed with some examples and problems. Here is the link Thanks for reading.

• +13

 » 6 years ago, # |   0 Can u give some related problems...?
•  » » 6 years ago, # ^ |   0 You don't actually need ones. Just remember the idea how to count the number of elements in a multiset that lie between l and r. When you'll encounter this subproblem, use the algorithm that was explained here.I mean that IMHO it's not a good idea to look for a problem, for which you know in advance using what algorithm you'll solve it (exception: the case when you need to practise quick coding of a standard algorithm).
•  » » 7 weeks ago, # ^ |   -7
•  » » 7 weeks ago, # ^ |   0 I think this one is similar https://atcoder.jp/contests/abc107/tasks/arc101_b
 » 7 weeks ago, # |   0 Well written.