Pinterest logoPinterest
Coding·45 minMembers

Elevator Assignment / Nearest Available Elevator

Members only

Given elevators described by current floor and state (up, down, or idle), plus a passenger's floor and desired direction, return the nearest eligible elevator's index or -1. The follow-up starts every...

SWE
simulation
scheduling
data-structure
medium
Frequency
Medium
Last asked
2026-09-16
Stage
phone-screen · onsite-coding

Log in to continue reading the full content

Comments

Sign in to join the discussion
Loading...