Minimum Number of Platforms

Asked atZoho
1Give yourself 5 minutes
2Answer out loud, not in your head
3Then compare with the answer below
0
Stuck? Show a way to structure it+
  1. 01Sort arrivals and departures separately
  2. 02Walk both lists with two pointers
  3. 03Allocate on the next arrival
  4. 04Release on the next departure
  5. 05Use the problem's equality rule consistently

Reference answer

Then expect these follow-ups

  • What comparison changes under half-open intervals?

    Tests: constraint adaptation

  • How would you return the busiest time interval?

    Tests: complexity analysis

Free to read · better with Enzo

Practice this out loud with Enzo

Enzo runs it as a mock interview, pushes back with follow-ups, and grades you on the rubric.

Next question