Recall & Review
beginner
What is a state machine in the context of elevator design?
A state machine is a model that represents the different states an elevator can be in (like moving up, moving down, idle, door open) and the transitions between these states based on events.
Click to reveal answer
beginner
Why is testing state machines important in elevator design?
Testing ensures the elevator behaves correctly in all states and transitions, preventing errors like doors opening while moving or skipping floors, which could cause safety issues.
Click to reveal answer
intermediate
How does an elevator's state machine handle multiple requests?
It manages requests by transitioning between states to serve floors efficiently, deciding when to move up or down, stop, or open doors based on queued requests.
Click to reveal answer
intermediate
What could happen if an elevator's state machine is not properly tested?
The elevator might behave unpredictably, causing safety hazards like moving with doors open, ignoring requests, or getting stuck between floors.
Click to reveal answer
beginner
Give a real-life example of a state transition in an elevator state machine.
When the elevator is idle at a floor and receives a request to go up, it transitions from 'idle' to 'moving up' state, then to 'door open' when it reaches the requested floor.
Click to reveal answer
What does a state machine in elevator design primarily represent?
✗ Incorrect
A state machine models the elevator's states and how it moves between them.
Why must elevator state machines be tested thoroughly?
✗ Incorrect
Testing ensures the elevator operates safely and correctly in all situations.
Which state might an elevator be in when waiting for a request?
✗ Incorrect
Idle means the elevator is waiting and not moving.
What could be a dangerous outcome of a faulty elevator state machine?
✗ Incorrect
Doors opening while moving is a serious safety hazard.
How does the elevator decide to move up or down?
✗ Incorrect
The elevator uses requests to decide direction.
Explain why elevator design uses state machines and why testing them is critical.
Think about how an elevator moves and reacts to button presses.
You got /5 concepts.
Describe a typical request flow in an elevator state machine from idle to door open.
Imagine pressing a floor button and what happens next.
You got /5 concepts.
