phil hunter wrote:For example, I created pacman and space invaders game, and also a BlackJack game. What design patterns should I have used for these? (Factory for first 2, Singleton for the last)
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
phil hunter wrote:Dont forget, Im just new to Design Patterns. Just looking some basic guidelines and some common design patterns to study up on..
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
phil hunter wrote:1) There are no generic or common patterns to use, it depends on what are you are trying to do.
2) Design Patterns come with experience and you should ask yourself has this problem been solved before with a Design Pattern.
3) You can write good clean code and then include the Design Pattern when you are refactoring.
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
Winston Gutkowski wrote:
Pretty much, but the experience comes in (hopefully) spotting them before you need to refactor.
Consider Paul's rocket mass heater. |