Segment Trees
A tree over an array that answers range queries (sum, min, max) and point updates in $O(\log n)$.
Advanced
Lazy propagation adds range updates.
Spotted a mistake or want to add detail? Suggest an improvement — Content Contributors' edits are reviewed by editors before they go live.
Discussion (0)
Sign in or join free to ask questions and discuss this topic.