← Box Interview Insights

Box·Software Engineer·Onsite - System Design / Architecture·Senior

SeniorPrefer not to say
May 2026

Summary

Box system design round focused entirely on elevator design, which sounds like a classic warm-up but went pretty deep pretty fast once they started pushing on multi-car scheduling and concurrency.

Questions Asked (5)

Q1

Design an object-oriented elevator system. Walk through the core entities, request types, scheduling logic, state transitions, and how you'd handle concurrency and edge cases.

System DesignTechnical Trade-offsData Modeling
Author's notes

I started with the obvious classes (Elevator, Floor, Building) and felt good for about two minutes.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying requirements (number of elevators, floors, traffic patterns) and then model the system using object-oriented principles, focusing on core entities, request handling, scheduling, state transitions, and concurrency. Walk through the design incrementally, discussing trade-offs and edge cases to demonstrate depth.

Pro tip: Emphasize separation of concerns: keep scheduling logic decoupled from elevator mechanics, and use design patterns like State, Strategy, and Observer to make the system extensible and testable.

1. Clarify Requirements and Scope

Ask about the number of elevators, floors, expected traffic patterns, and any special features (e.g., priority requests, maintenance mode). This ensures the design meets the actual needs.

2. Identify Core Entities and Relationships

Define classes such as Elevator, Floor, Request, Scheduler, and ElevatorSystem. Establish their attributes, methods, and associations (e.g., one system manages multiple elevators).

3. Design Request Handling and Scheduling

Model internal and external requests, and choose a scheduling algorithm (e.g., SCAN, LOOK, or destination dispatch). Explain how requests are assigned to elevators and how the scheduler optimizes for metrics like wait time.

4. Define State Transitions and Concurrency

Describe elevator states (Idle, Moving, Stopped, Maintenance) and transitions triggered by events. Address concurrency: use locks, queues, or actor model to handle simultaneous requests and state changes safely.

5. Discuss Edge Cases and Trade-offs

Cover scenarios like overload, emergency stops, power failures, and multiple requests to the same floor. Discuss trade-offs between simplicity and efficiency, and how design patterns (State, Strategy, Observer) help manage complexity.

Key Points to Mention

  • Use of design patterns: State for elevator states, Strategy for scheduling algorithms, Observer for notifying floors/elevators.
  • Scheduling algorithm details: SCAN/LOOK vs. destination dispatch, and how to handle up/down requests efficiently.
  • Concurrency mechanisms: thread-safe request queues, locks, or message passing to avoid race conditions.
  • State machine for elevator: clear transitions (e.g., Idle -> Moving -> Stopped -> Idle) and handling of door open/close.
  • Edge cases: overload detection, emergency stop, power outage recovery, and handling requests for the same floor from multiple passengers.
  • Scalability and extensibility: how to add more elevators or floors without major redesign, and how to monitor system performance.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q2

How would you differentiate between an external hall call (someone pressing up or down on a floor) and an internal floor selection (a passenger choosing a destination inside the car), and what does that mean for your request model?

System DesignTechnical Trade-offs
Author's notes

Didn't expect them to drill into request types specifically.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying that external hall calls and internal floor selections are distinct request types with different origins, priorities, and semantics. Then explain how to model them separately in your system—using different request objects or fields—to enable correct scheduling, routing, and user feedback. Emphasize that this distinction is critical for safety, efficiency, and a good passenger experience.

Pro tip: Mention that external calls often need to be assigned to a specific elevator based on direction and proximity, while internal selections are binding commitments for that car—this shows you understand real-world elevator dispatch logic and its impact on system design.

1. Define the two request types

Clearly state that an external hall call is a request from a landing (floor + direction) for any available car, while an internal floor selection is a request from inside a specific car for a destination floor.

2. Identify key differences

Highlight differences in origin (outside vs inside), scope (any car vs specific car), directionality (up/down vs destination), and priority (external calls may be assigned, internal selections are binding).

3. Model as separate request objects

Propose modeling them as distinct types (e.g., HallCall and CarCall) with shared fields like floor and timestamp, but unique fields like direction for hall calls and car ID for car calls.

4. Explain implications for scheduling

Describe how the system uses these models: hall calls are queued and assigned to cars via a dispatcher, while car calls are added to the car's internal route and affect its movement directly.

5. Discuss trade-offs and edge cases

Address trade-offs like merging requests for efficiency vs keeping them separate for clarity, and edge cases like a hall call and car call for the same floor/direction.

Key Points to Mention

  • Origin and scope: external calls are from landings and can be served by any car; internal selections are from inside a car and are car-specific.
  • Directionality: hall calls include direction (up/down), while internal selections specify a destination floor.
  • Request model: use separate classes or types (e.g., HallCall vs CarCall) with shared attributes like floor and timestamp.
  • Scheduling impact: hall calls require assignment logic (dispatcher), while car calls directly modify the car's route.
  • Priority and binding: internal selections are commitments for that car; hall calls may be reassigned or grouped.
  • User feedback: external calls need indicators (e.g., which car is coming), internal selections need confirmation of destination.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q3

Walk through the state transitions for a single elevator car, including how you'd handle a maintenance or out-of-service state.

System DesignData Modeling
Author's notes

This part went well.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by defining the elevator's states and the events that trigger transitions, then walk through the normal operation cycle before covering exceptional states like maintenance. Emphasize how you'd model this as a state machine with clear entry/exit actions and guards to ensure safety and correctness.

Pro tip: Explicitly call out safety invariants (e.g., doors must be closed before moving) and how the maintenance state overrides all others, showing you think about real-world constraints and failure modes.

1. Define the states

List the core states: Idle, Moving Up, Moving Down, Doors Open, and Maintenance/Out-of-Service. Briefly describe what each state represents.

2. Identify events and transitions

Map events (e.g., floor request, arrival at floor, door obstruction, maintenance toggle) to valid transitions between states, noting any guards or conditions.

3. Walk through normal operation

Trace a typical sequence: Idle -> Moving Up -> Doors Open -> Idle, highlighting entry/exit actions like starting/stopping the motor and opening/closing doors.

4. Handle maintenance/out-of-service

Explain how the system enters Maintenance (e.g., via manual switch or fault detection), what happens to pending requests, and how it safely returns to service.

5. Discuss edge cases and invariants

Mention safety invariants (e.g., never move with doors open), error handling (e.g., power loss), and how the state machine ensures consistency.

Key Points to Mention

  • State machine modeling with states, events, transitions, guards, and actions.
  • Safety invariants: doors closed before movement, emergency stop behavior.
  • Maintenance state as a superstate that overrides normal operation and clears pending requests.
  • Handling of concurrent events (e.g., multiple floor requests) and prioritization.
  • Recovery from faults: how the system detects issues and transitions to maintenance.
  • Testing and validation of state transitions, including edge cases like power failure.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q4

How would you extend the system to support express elevators or VIP priority requests without rewriting the core scheduling logic?

System DesignTechnical Trade-offsAdaptability & Ambiguity
Author's notes

Classic extensibility question.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the current scheduling architecture and identifying extension points, then propose a design that introduces abstraction layers (e.g., strategy pattern, priority queues) to handle express elevators and VIP requests without modifying core logic. Emphasize trade-offs like added complexity, latency, and fairness, and discuss how to validate the extension with tests and metrics.

Pro tip: Show that you prioritize backward compatibility and incremental rollout—e.g., feature flags or A/B testing—to mitigate risk. Mention that you'd first write a design doc and get feedback from stakeholders to ensure alignment.

1. Clarify Requirements and Constraints

Ask questions to understand the current system, expected load, VIP definition, and non-functional requirements like latency and fairness. This ensures your solution addresses the real problem.

2. Identify Extension Points

Analyze the existing scheduling logic to find seams where new behavior can be plugged in, such as request classification, priority assignment, or elevator selection.

3. Propose an Extensible Design

Suggest using design patterns like Strategy, Chain of Responsibility, or Observer to decouple core scheduling from priority handling. For example, a priority queue for VIP requests and a separate queue for express elevators.

4. Discuss Trade-offs and Mitigations

Evaluate pros and cons: increased complexity, potential starvation of normal requests, and performance impact. Propose mitigations like aging, quotas, or dynamic priority adjustment.

5. Plan for Testing and Rollout

Outline how to test the extension (unit, integration, simulation) and roll it out gradually (feature flags, canary releases) to minimize disruption.

Key Points to Mention

  • Open/Closed Principle: extend behavior without modifying existing code.
  • Strategy pattern for interchangeable scheduling algorithms.
  • Priority queue or multiple queues for VIP/express requests.
  • Fairness and starvation prevention (e.g., aging, quotas).
  • Backward compatibility and incremental rollout (feature flags).
  • Observability: metrics, logging, and monitoring for new paths.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q5

How do you handle concurrent requests arriving simultaneously, say multiple hall calls across different floors at the same time?

System DesignTechnical Trade-offsAlgorithms & Data Structures
Author's notes

Rough.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Clarify the scenario as a classic elevator scheduling problem, then outline a concurrent request-handling strategy using a central dispatcher with a priority queue and locking or actor model. Discuss trade-offs between fairness, efficiency, and starvation, and mention how you would test and monitor the system under load.

Pro tip: Acknowledge that the elevator problem is a metaphor for any shared resource with concurrent requests—show you can generalize to rate limiting, load balancing, or task queues, which demonstrates system design maturity.

1. Clarify requirements and constraints

Ask about scale (number of elevators, floors, request rate), latency SLAs, fairness vs. throughput, and failure modes. This shows you don't jump to solutions without understanding the problem.

2. Model the system and concurrency

Describe the components: request queue, dispatcher, elevator state, and shared data structures. Explain how you would handle simultaneous access—e.g., locks, message queues, or actor model—and why.

3. Choose a scheduling algorithm

Propose an algorithm like SCAN (elevator algorithm), LOOK, or a priority-based approach. Discuss how it handles multiple simultaneous calls and prevents starvation or excessive wait times.

4. Address trade-offs and edge cases

Compare fairness vs. efficiency, discuss handling of priority requests (e.g., emergency), and how to deal with overload or failures. Mention idempotency and retries if applicable.

5. Validate and iterate

Explain how you would test the design with simulations, load tests, and metrics (e.g., average wait time, throughput). Mention monitoring and the ability to adjust scheduling dynamically.

Key Points to Mention

  • Concurrency control mechanisms: mutexes, semaphores, or actor-based models to serialize access to shared state.
  • Scheduling algorithms: SCAN/LOOK for efficiency, or priority queues for fairness; discuss starvation avoidance.
  • Trade-offs: latency vs. throughput, fairness vs. efficiency, and how to balance them based on requirements.
  • Scalability: partitioning requests by floor or elevator bank, and using distributed queues if needed.
  • Fault tolerance: handling elevator failures, request retries, and ensuring no lost requests.
  • Monitoring and metrics: tracking wait times, queue lengths, and system load to inform dynamic adjustments.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.