re: Clean code... Why bother? VIEW POST


Better naming the identifiers is one of the harder tasks

It would be good to research more about how that affects the understanding of the code.

For example giving negated names for boolean variables like: no_update

When negating that it would be:

if not no_update then...

It would be better:

if update then..


This is the case where you'd really scratch your head when encountered.


For me, name booleans with question identifiers. Like "is updated" or "hasBeenUpdated". Then you get code like "if(hasBeenUpdated)" and it makes more sense linguistically. However, if you work with members who aren't super fluent in English it becomes tough, because English is totally a tricky language.


I try to do this as well, makes it easier to read.

code of conduct - report abuse