Design Meeting Scheduler

Difficulty: MEDIUMCategory: LLDFrequency: 1Asked On 2025-06-24

Problem Statement

Design a system to schedule meetings in an office that has n meeting rooms. The system will continuously receive booking requests defined by a start time and end time, and must allocate any available room that is free during the requested time window.


Functional Requirements:

1.Booking Requests:
•Accept requests in the form of (start_time, end_time).
•Allocate any room that is available during the requested time.
•Reject the request if no room is available.
2.Meeting Room Allocation:
•Optimize room utilization.
•Support efficient querying for room availability.
3.System Behavior:
•Assume start and end times are integers or timestamps.
•Overlapping meetings in the same room are not allowed.


Design Expectations:

•Model key classes (e.g., MeetingRoom, BookingRequest, Scheduler, etc.).
•Define class interactions and responsibilities.
•Apply appropriate object-oriented design principles (e.g., SOLID).
•Use relevant design patterns if applicable (e.g., Strategy, Factory, etc.).
•Design for extensibility (e.g., support cancellation, room priorities, or recurring meetings in future).


Constraints (Optional to Include):

•All bookings are for the same day.
•No need to persist bookings across application restarts (in-memory storage is fine for now).


Interview Experience asked in: https://www.interviewstop.com/InterviewPrep/InterviewExperiences/uber-sde-2-interview-experience-india?company=Uber&role=Software+Engineer+II

Solution

Comments