If code is well written, it doesn’t need to be commented. True?

I’m not sure where this myth started but this is one I wish would disappear quickly.  This is another argument I hear often from developers that don’t like maintaining comments in code.  The assumption is that if all developers on the project were to write flawless, self-explanatory and similarly formatted code, no value would be obtained from the addition of comments.  I even had a hard time writing that one without a chuckle.  

It’s a noble statement for sure, and if such well written code existed, I might even consider this plausible.  However, in the times I’ve heard this statement, it’s yet to be coupled with code that is sufficiently self explanatory, perfectly structured, whose logic is concise, variables that are non-cryptic.

Perfect Code

In the religion of coding conventions, there’s no greater misconception than the belief of perfect code.  What’s perfect to one person is mediocre to the next.  One coder’s idea of perfect organization methodology is chaos and clutter to the next.  It’s impossible to achieve perfection when the rules are based on personal preference.  This is why, some level of commenting and/or documentation is vital to any project.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.