(99+) Can anyone give an interval tree based solution? - LeetCode Discuss
Why do you want to use an interval tree for that? It's overkill. You don't need to support overlapping intervals. So you can just use for example a sorted set like @wddd did.
Read full article from (99+) Can anyone give an interval tree based solution? - LeetCode Discuss
No comments:
Post a Comment