completed the design patterns part