Implemented command and memento patterns
Commiting pattern trials code.