go to start Good Comments Bad Comments
|home |print view |recent changes |changed April 4, 2008 |
exact
|You are 54.234.67.55 <- set your identity!

A bad comment is something that describes /what/ the code is doing. This is bad because you can get this information by reading the code and by better choices of identifier names.

A good comment is something that describes /why/ the code is doing something. This is part of documenting the design decisions at the micro level. Why did you choose to use a particular algorithm?

Comments should be used sparingly.


|home |print view |recent changes |changed April 4, 2008 |
exact
|You are 54.234.67.55 <- set your identity!

Good Comments Bad Comments
go to start