dsa1 min read
My Calendar I — Sorted Dict / Segment Tree
Book events without double-booking. Use sorted dictionary to find previous and next events; check overlap with both.
Read →
webcoderspeed.com
2 articles
Book events without double-booking. Use sorted dictionary to find previous and next events; check overlap with both.
Track coverage of half-open intervals. addRange, removeRange, queryRange. Sorted dictionary of disjoint intervals with merge/split logic.