Link Details

Link 98375 thumbnail
User 291091 avatar

By DigitalDuffman
via krissteele.net
Published: Jul 27 2008 / 14:10

Why it's okay to use comments, even though the man will tell you it's wrong.
  • 17
  • 2
  • 1235
  • 341

Comments

Add your comment
User 261293 avatar

joecoder replied ago:

-1 votes Vote down Vote up Reply

Dude, use unit tests instead of comments to determine if your code works correctly. The latter approach will land you that job at Wendy's sooner than you expect.

This whole debate seems to boil down to a preference for good readable code with nonredundant (DRY) useful comments versus bad, or mediocre or even good code with extensive, redundant and possibly inaccurate comments.

It's not a black/white debate of comments versus no comments. That's a strawman that's useful for generating blog rants but not of much practical benefit.

User 282283 avatar

Tantalus replied ago:

0 votes Vote down Vote up Reply

It's sheer lunacy to think that there is never a time when code has to be commented to understand what it's supposed to be doing.

Add your comment


Html tags not supported. Reply is editable for 5 minutes. Use [code lang="java|ruby|sql|css|xml"][/code] to post code snippets.