added example for state pattern. all GoF pattern done!