Andrey Polischuk

Code without comments

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:

  1. Comment is a waste for compilers.

  2. Nobody will support comment written once. It most likely will become smell and create misunderstanding in the future.

  3. The more comments the more enormous modules we have.

  4. Comment means that code is complicated.

  5. 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