Use of Stacks
Two stacks are used.
One keeps track of the numbers read so far; the other keeps track of the operations read so far.
When an operation is read, it is pushed in the operation stack.
When a number is read, it is pushed in the number stack.
Previous slide
Next slide
Back to first slide
View graphic version