Every interval problem here came down to choosing an order and then trusting it. This is the question that made each sweep work:
| Exercise | The question that unlocked it |
|---|---|
| Spot Double-Booked Meetings | Once meetings are in start order, which meeting could the next one possibly clash with? |
| Merge Busy Calendar Blocks | Does this block start before the last merged block ends, and whose pair am I changing? |
| Find When Two Calendars Overlap | Which slot ends first, and can it still overlap anything later in the other list? |
| Fewest Cancellations to Clear Conflicts | Of the requests that still fit, which one leaves the studio free soonest? |
| Review an AI-Written Schedule Sorter | What does this comparator return, and whose array and objects does this code change? |
A quick self-check: think of the test that stayed red the longest for you. Which assumption in your code did it break? Interviewers often ask exactly that kind of question, and it’s a lot easier to answer once you’ve talked it through.
Want a second pair of eyes on your Sorting and Intervals work?
From here on, the label comes off. Mixed Practice hands you problems without saying whether they need a stack, a queue, or a sort, just like an interviewer would.