As requested, here's a demo of the command pattern in action. This example shows how to use the Command Pattern to undo an action. Please watch the video in the previous post before browsing through this source.
Try to focus on how the commands are all added into the command stack, then you'll see how the stack can be used for undoing, redoing, logging actions, queuing actions, and all sorts of other useful stuff :)
Click on the green, red, and blue boxes to create new circles. Click on the black box to undo.