5 ms·
I think Jeff Atwood sums things up nicely: http://www.codinghorror.com/blog/2008/07/coding-without-comments.html http://www.codinghorror.com/blog/2008/07/coding
by rrreese 14y ago
I think Jeff Atwood sums things up nicely: http://www.codinghorror.com/blog/2008/07/coding-without-comments.html http://www.codinghorror.com/blog/2008/07/coding-without-comm...
- dagw 14y agoExcept In my opinion he gets it very wrong. His comment free code doesn't include the the string "Newton-Raphson" anywhere, making it non-trivial for anyone not familiar with the code to work out what is going on. Secondly, and more importantly, he never explains why he is using Newton-Raphson to approximate the square root. If I was handed this in some code I was to maintain I would really really like to know that.
- arithma 14y agoNote the he does say the following: When you've rewritten, refactored, and rearchitected your code a dozen times to make it easy for your fellow developers to read and understand -- when you can't possibly imagine any conceivable way your code could be changed to become more straightforward and obvious -- then, and only then, should you feel compelled to add a comment explaining what your code does. It does make sense.