Peak number of concurrent live orders
Asked at IMC, Flow Traders
Each order is live over an interval [start, end]. Find the largest number of orders that are simultaneously live at any instant.
orders = [[1, 4], [2, 5], [7, 8]]
-> 2 # [1,4] and [2,5] overlap
Return the peak concurrency. Aim for .
Your answer
This one is open-ended. Work it through, then check your reasoning against the full solution.