The goal is the implementation a basic elevator simulation. The elevator stops at each requested floor. There are not such things as parallel calls for this challange, everything is rather sequential for this challenge.
- The simulator runs everything within the main() function for now
- the elevator range is between a base floor (0) and maximum floor (6), these are statically defined as constants in the script
- The elevator should accept floor requests (which can simulate persons standing in a specific floor and requesting the lift) and process the requested floors in the order they have been received
- When the elevator moves it should log the floors it passes and it should log its arrival in the requested floor
- consecutive duplicate requests (e.g. 4,4, 1, 2, 2) should be removed to prevent the elevator from stopping at the same floor multiple times in a row
- In the simulation it starts in a idle state and initial requests should trigger the movement
- Start is at basement floor as default
- Multiple requests are being made
- Requests are being processed and the elevator should move inbetween those requests, until no request is left
- Simulation variance and input: the simulation for now is completely static and the order fixed. For more real-world (test) scenarios the input could be via CLI command and the requests could be simulated in a random list
- Idle state: Atm there is no automated way to move the elvator back from idle state into movement
- Request Order: Requests are currently processed in the order they were received. This is usually not the most efficient route, a different scheduling and grouping of requests could be maybe helpful here
- Scalability: The number of requests could grow and the scripts become more inefficient, due to repeating list operations
- No real time and async processing: Everything is for now sequentially processed, this is not close to reality