File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes GOF vs Head First Design Patterns Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "GOF vs Head First Design Patterns" Watch "GOF vs Head First Design Patterns" New topic

GOF vs Head First Design Patterns

Nikhil Jain
Ranch Hand

Joined: May 15, 2005
Posts: 385
Which is the better of the two? I find GOF too hard to understand & the given examples are more mathematical.

SCJP 1.4, SCWCD 1.4, SCBCD 1.5
Christophe Verré

Joined: Nov 24, 2005
Posts: 14687

Head First Design Patterns does not contain all of the GOF patterns. GOF is not that hard to follow, if you take one pattern at a time, and try to code the patterns according to the class diagrams.

[My Blog]
All roads lead to JavaRanch
Rishi Shehrawat
Ranch Hand

Joined: Aug 11, 2010
Posts: 218

I found Head First Design Patterns much easier to read than GOF.
raj sirohi
Ranch Hand

Joined: Mar 02, 2010
Posts: 35
Hi Nikhil,
I didnt read GOF at all, I dropped it after 3 chapter, HFDP is far better , here is the link to my post


Mika Tapanainen
Ranch Hand

Joined: Jun 11, 2009
Posts: 95

I didn't read both of the books and I passed (but score was 65%). I read for the exam about the patterns only the Cade's and Sheil's book and the Java Camp design patterns pages



Mihai Lihatchi
Ranch Hand

Joined: Oct 28, 2005
Posts: 138

I do not remember very well right now because I read HFDP in 2007 (and it belonged to a friend) but I think the book was designed as a Java equivalent of Gang of Four .

However I still think that even though GoF is old and addresses a C/C++ audience it is still worth a look because it is a classic. Some concepts never get old and however brilliant the Head First authors are (and I mean it they are ) they are still basing the book on GoF ( I remember this from the introduction ).

Regarding SCEA preparation : I used both GoF and HFDP in my preparation but also my experience as a Java developer. Patterns are nothing more than recurring solutions to problems so your experience should help as well. Even during assignment you should question whether you need to use a pattern or not .. don't try to stuff a pattern in the solution unless you are sure it brings value to your design.
I passed the beta so .. don't take my words for granted regarding the actual SCEA exam

Better, faster, lighter Java ... you mean Ruby right ?
SCEA5,SCBCD1.3,SCWCD5,SCJP1.4 - memories from my youth.
Gian Franco
Ranch Hand

Joined: Dec 16, 2003
Posts: 977
HFDP leans on the seminal work of the GOF.

In their book the GOF say:

"The choice of programming language is important because it influences
one's point of view. Our patterns assume Smalltalk/C++-level language features,
and that choice determines what can and cannot be implemented easily. If we
assumed procedural languages, we might have included design patterns called
'Inheritance,' 'Encapsulation,' and 'Polymorphism.'"

My language of choice is Java which is one of the reasons why I preferred HFDP.

"Eppur si muove!"
Remko Strating
Ranch Hand

Joined: Dec 28, 2006
Posts: 893
I'm reading both. I use GOF for a more general view over de concepts with I could use for different other languages and as a way of thinking and concepts for different problems and using Design Patterns for a more practical approach.

Remko (My website)
SCJP 1.5, SCWCD 1.4, SCDJWS 1.4, SCBCD 1.5, ITIL(Manager), Prince2(Practitioner), Reading/ gaining experience for SCEA,
Kuppusamy Venkatasubramanian
Ranch Hand

Joined: Dec 30, 2004
Posts: 91

I too started GOF but couldn't continue as it is too conceptual to understand. I read HeadFirst twice. HeadFirst rocks and makes the patterns stick with great examples. It makes you to correlate the examples with pattern if you don't get the pattern in the first place. I witnessed this especially with Decorator pattern.


SCJP1.4, SCBCD 1.3, SCWCD 1.4, SCEA 5, JLPT-N3
My Blog
Heilien Tsui

Joined: Dec 08, 2008
Posts: 20
I find that the code sample from wikipedia for Design Pattern (from GOF) is easier to understand. maybe for a good start to learn the Design Patterns

Rajiv Shr
Ranch Hand

Joined: Aug 11, 2010
Posts: 37
Wikipedia all the way
albert smith

Joined: Sep 19, 2008
Posts: 4
GOF Design Patterns are the original one and they appeared in mid 90's. They are great and they were written with c++ and smalltalk in mind. Since then people used the design patterns in practice instead of theory and they noticed some of them are useless or have better alternatives and some are easier to implement in modern languages(like java) due to new features like reflection. Some patterns are limited because some features are not provided in modern languages(multiple inheritance). Of course the term of design patterns was enlarged to new categories like enterprise patterns,....

Personally, I find HeadFirst patterns easier to understand than the original GOF patterns.
Andrew Monkhouse
author and jackaroo
Marshal Commander

Joined: Mar 28, 2003
Posts: 11404

albert smith wrote:Since then people used the design patterns in practice instead of theory and they noticed some of them are useless or have better alternatives

I have a bit of a problem with that specific sentence...

In my experience, people who have been developing for some time tend to pick up a design patterns book (GOF or other book) and say something like "so that's the name of what I've been doing all this time".

The GOF book, and those that came after it, did not invent the patterns in an ivory tower. These were patterns that were seen time and time again in real code.

Where people had a problem is when they came from a theoretical background and tried to apply a specific pattern to a particular problem, and found that they created more problems for themselves than they solved. This is typically described as "I have a hammer, so everything looks like a nail". I also have an image in my mind of a child's TV show where the host of the show is saying (in their usual bright, bubbly way): hey kids, today we are going to implement the factory pattern - yay!!!
P Das
Ranch Hand

Joined: Jun 30, 2008
Posts: 123
My twopence: please do not neglect GoF.

If you have difficulty, start with some pattern like Singleton.

There is no hard and fast rule that you have to follow in the order the book follows (at least not all cases).

You may find interest after you saw some of the crisp definitions of GoF work with you.

Happy reading!

Pranab Das, PMP, SCEA
Luke Murphy
Ranch Hand

Joined: May 12, 2010
Posts: 300
Nikhil Jain wrote:Which is the better of the two? I find GOF too hard to understand & the given examples are more mathematical.

If you are just a developer and dont' need to know Design Patterns inside out, then you might be ok with Head First. Otherwise I'd avoid it and go with GoF. You'd want to have a very good understanding of GoF before attempting this exam.

Chrix Wu
Ranch Hand

Joined: Nov 15, 2009
Posts: 121
in the head first book, it says, "read this, then you are well prepared to read the GOF book".

my opinion, head first book, first, then read GOF if you got time

** SCJP 5.0 84% **
** SCWCD 1.5 76% **
I agree. Here's the link:
subject: GOF vs Head First Design Patterns
Similar Threads
how many design patterns are there?
WA #1.....word association
Go for Head First Design Patterns or GOF Design Pattern book?
interesting interview with Rod Johnson
GOF pattern VS J2EE pattern