The Pragmatic Craftsman         :: Simplicity from complexity :: | About Me |

You are here: The Pragmatic Craftsman > Better Coder

Go to: « Debugging | Java Programming Notes »

What is Good Code?

I recently discovered a pretty good discussion on what "good code" is. The original author, Bill Carlson, specified quite a few good points. Points that according to him make the code good. Before I list the summary of the points, let me just say that if you are interesting in writing quality code, I think you should (you must) read Steve McConnell's Code Complete. It will open your eyes. It opened mine. :-) (See my review in Books I Recommend.)

Attributes of "Good Code:"

  • High "signal to noise" ratio.
  • Minimal algorithmic complexity.
  • Lack of "cuteness".
  • Use of most primitive technology required.
  • Appropriate optimization.
  • Architectural simplicity.
  • Specificity (avoiding over-generalization).
  • When vs. How comments. Knowing how to use a class: useful. Knowing when to use a class: priceless.
  • Appropriate quality bar.
  • 100% reachable code.
  • Lack of cut-n-paste.
  • Lack of redundency.
  • Visual clarity. Is the code easy to read?

Read the whole discussion on The Old Joel on Software Forum: "Good Code" - What is it?


Comments

Post a comment









Remember personal info?







Go to:
   « previous entry: Debugging
   » next entry: Java Programming Notes

Random Quote

Search

 

Topics

Architecture & Design :12
Better Coder :29
Books :43
Books Recommended :18
Buzzwords :5
Career :25
Craftsmanship :15
Java :15
Quotes :25
Recommended :9
Software Engineering :3
Uncategorized :33
Web Development :1

Archive

May 2008 (1)
April 2008 (2)
March 2008 (1)
February 2008 (1)
January 2008 (2)
November 2007 (1)
October 2007 (3)
August 2007 (3)

...since January 2002

Currently Reading


:: See list of books I finished reading

Info

© 2001-2008 Stanley Kubasek About me :: Contact me