DEV Community

Discussion on: "Do not comment on your code, it should be self-documented". Well... I don't agree.

Collapse
 
dezbrown profile image
deZbrown

When you run into a function that is hard to read, after you get the job of understanding it, do a refactor in such a way that the next time you come across that function, it's easy to read. No, need to do comments if you invest in code improvement. And code improvment is investment as comment writing is debth.