Say I have a list of lists that has indexes [[start, end], [start1, end1], [start2, end2]].
[[start, end], [start1, end1], [start2, end2]]
Like for example :
[[0, 133], [78, 100], [25,
ascending sort all items by length.
add them to a segment tree and ignore overlapped items.