Dsa
Intervals
Easy
Meeting Room Availability
You are given a list of meetings, each defined by a start and end time. Determine if all meetings can be scheduled without overlapping. Each meeting is represented by a pair of integers (start, end). Write a function that checks if it is possible to schedule all meetings. An example format for input: '3
0 30
5 10
15 20' means there are 3 meetings with specified start and end times.
Input:
N
start1 end1
start2 end2
...
Output:
'Possible' or 'Not Possible'.
Example:
Input:
3
0 30
5 10
15 20
Output:
Possible
Key concepts
intervalssortinggreedy
Practise this out loud — free
Start a mock interview on THIS exact question — a voice AI interviewer opens with it, pushes back like a real onsite, then hands you an instant scorecard.
🎙 Practise this question now