Example: Reversing a Word
Declare a stack of characters.
While (there are more characters to read) Read a character, and push it onto the stack.
While (the stack is not empty) Pop a character off the stack, and write that character to the screen.
Previous slide
Next slide
Back to first slide
View graphic version