Minimum machines to run overlapping jobs
Asked at Citadel, Two Sigma
A batch of backtest jobs each occupy a machine over a half-open interval [start, end). Two jobs can share a machine only if they do not overlap.
jobs = [(0, 30), (5, 10), (15, 20)]
min_machines(jobs) -> 2
Return the minimum number of machines needed to run all jobs. This equals the maximum number that are ever running at once. What is the cost?
Your answer
This one is open-ended. Work it through, then check your reasoning against the full solution.