Segment TreeΒΆ
Segment tree is a data structure designed for storing one-dimensional intervals or segments, either overlapping or non-overlapping. It is useful for detecting all the segments that contain a specific point. Each segment has start and end positions where the start position is inclusive while the end position is not. The version of segment tree implemented in mdds allows associating a value with each segment so that you can use it as an associative container.