3 ms·
| any misunderstandings are prevented If only this were the case. Comments are frequently wrong- they were either wrong from the beginning, unhelpful, or neve
by kansface 13y ago
| any misunderstandings are prevented
If only this were the case. Comments are frequently wrong- they were either wrong from the beginning, unhelpful, or never updated when code was changed. Whenever I find myself writing a comment, it is typically because I just wrote bad code. Sometimes, bad code is necessary; most of the time, its better to get rid of the comment and the bad code.
Ultimately, comments are not sufficient; you have to read the code anyway. Comments can only be useful in the regard of recording the intent of the author.