These are the core operations we need for the elevator-simulator
application. In the elevator simulator:
- The records are events.
- The keys are the time at which those events will occur.
- We always want to execute the event with the ``smallest time''
(closest to the present).
- Executing an event may result in other future events (elevator
arriving at lobby and picking up passengers results in elevator
planning to arrive at 5th floor at time t+20 seconds).
One nice implementation of a priority queue is the heap.
Next: Heap Definition
Up: HEAPS
Previous: Priority Queue