practice a little every day — you've got this ♡
Greedy & Intervals Interview Problems
Practice 5969 original coding, SQL, system design, machine learning and behavioral problems across 15 topics. Coding and SQL problems run against hidden test cases right in your browser; every problem has hints and a worked solution, free.
- 5969
- Problems
- 2211
- Auto-graded
- 15
- Topics
- 272
- Added today
Showing 151–161 of 161 results
- Greedy & IntervalsHardAuto-gradedMinimum Guards to Cover All Museum Gallery Segments
Tests ability to apply a sweep-line with a greedy exchange argument to optimally place point guards that each cover a fixed-radius interval on a 1-D gallery.
Greedy & Intervalsgreedyintervalssweep line - Greedy & IntervalsMediumAuto-gradedAssign Tasks to Time Slots with Minimum Idle Penalty
Tests the exchange-argument greedy technique by scheduling deadline-bearing tasks into time slots to minimize total weighted idle (missed-deadline) penalty.
Greedy & Intervalsgreedyintervalsschedulingexchange argument - Greedy & IntervalsMediumAuto-gradedMaximize Completed Jobs with Deadlines
Tests greedy scheduling with deadlines: select and order unit-length jobs to maximize total profit, applying an exchange argument to prove optimality.
Greedy & Intervalsgreedyschedulingsorting - Greedy & IntervalsMediumAuto-gradedMaximum Simultaneous Room Bookings
Tests the sweep line technique on interval scheduling to find the peak number of overlapping room bookings over a timeline.
Greedy & Intervalssweep lineintervalsgreedy - Greedy & IntervalsMediumAuto-gradedMinimize Maximum Job Lateness with Deadlines
Tests the classic exchange-argument greedy insight: scheduling jobs by earliest deadline minimizes the maximum lateness over all jobs.
Greedy & Intervalsgreedyintervalssortingexchange-argument - Greedy & IntervalsMediumAuto-gradedMinimum Penalty Class Schedule with Fixed Breaks
Tests whether a candidate can apply an exchange-argument greedy to order tasks with deadlines and penalties to minimize total weighted lateness, with fixed unavailable time windows.
Greedy & Intervalsgreedyintervalsschedulingexchange argument - Greedy & IntervalsHardAuto-gradedMinimum Penalty Task Schedule with Deadlines
Tests the classic exchange-argument greedy insight that scheduling jobs by deadline minimizes total weighted lateness on a single machine.
Greedy & Intervalsgreedyintervalsschedulingexchange-argument - Greedy & IntervalsMediumAuto-gradedMaximum Coverage From Non-Overlapping Intervals
Tests ability to merge overlapping intervals and use a greedy sweep to find the maximum total length covered by selecting at most K non-overlapping merged segments.
Greedy & Intervalsgreedyintervalssorting - Greedy & IntervalsMediumAuto-gradedMinimum Breaks to Cover All Shifts with Rest Windows
Tests whether a candidate can apply an exchange-argument greedy to schedule the fewest rest-window insertions so every worker shift is covered without violating a maximum continuous-work limit.
Greedy & Intervalsgreedyintervalsschedulingexchange argument - Greedy & IntervalsEasyAuto-gradedCount Peak Hours Across Venue Time Slots
Tests the ability to use a sweep line (difference array) to efficiently count how many time slots are simultaneously "active" and find the maximum overlap count.
Greedy & Intervalsgreedyintervalssweep line - Greedy & IntervalsEasyAuto-gradedMaximize Jobs Completed Before Their Deadlines
Tests greedy scheduling with deadlines: select and order unit-duration jobs to maximize the count of jobs finished on or before their individual deadlines.
Greedy & Intervalsgreedyintervalssorting