Code without comments
Let’s explain yourself in code without a bunch of comments. And that’s why.
Ideally code should be neat, clean and odorless. But in real world we everyday work with a mass of ugly and smelly commented code.
I have five reasons to avoid comments:
- Comment is a waste for compilers.
- Nobody will support comment written once. It most likely will become smell and create misunderstanding in the future.
- The more comments the more enormous modules we have.
- Comment means that code is complicated.
- Better comment is a meaningful name for variable, function or class. You can extract some code part to them to explain how this part works.
Let’s create a clean self-explaining code:
Explain yourself in code ☺️ #cleancode pic.twitter.com/UlpipWO3Oq
— David Santos (@dsantosmerino) April 23, 2017