learning about design pattern