5 ms·
The “exception” section pretty much describes why you should use comments. The other examples are just bad comments. A comment like “delay for 5 seconds” is ba
by orev 5y ago
The “exception” section pretty much describes why you should use comments. The other examples are just bad comments.
A comment like “delay for 5 seconds” is bad and easily goes out of date because you might change the number of seconds in the code without updating the comment. The comment should be something like “wait a few seconds for foo the settle down” to explain why you’re doing (such a horrible hack).