Designing The POP Operation
We use node-and-arc diagrams to work out the necessary steps. We must
draw before and after pictures.
Here is a typical before picture:
Here is the picture after the POP operation:
The changes are:
- the node containing 29 is gone.
- in S, the TOP pointer is pointing at a different node.