Data Structures
Fenwick Trees:Prefix Updates When a Segment Tree Is More Tree Than You Need
A Fenwick tree (BIT) stores prefix aggregates in an array using least-significant-bit jumps. Point update and prefix query in O(log n) with less machinery than a segment tree.
Read More