2 ms·
> "comments go out of date quickly, so there's no point in investing in them" The key difference is where the described thing lives. A comment describing the
by sooyoo 4y ago
> "comments go out of date quickly, so there's no point in investing in them"
The key difference is where the described thing lives.
A comment describing the next few lines of code or some loop that follows, or similar, won't go out of date since it's easily updated together with what it describes.
A comment living in another file, describing loosely some far-reaching but still-evolving aspect will likely be outdated soon, if the thing it describes changes and that comment is out of sight and needs extra effort to be remembered and updated.