How to judge code
Code,  Mini essays

How to judge code – part I

How to judge code is a tricky question. With all the clean code rules, KISS, DRY, YAGNI, SOLDI and so on and so forth one can go crazy and question ones sanity in the end. What i wanted to throw out there is to judge the code be a very simple rule the encompasses multiple different one, is not straightforward and is very flexible.

How to judge code ?

Judge the code by how easy it is to debug

We all know that one person at a company that knows all the quirks and secret sauce of a language, pipes, default interfaces and so on…. that person also knows the system very well which allows to make even more mental shortcuts while writing busines logic without explaning it explicitly.

Now don`t get me wrong…

Everyone should have a decent understanding of a language BUT i think it shoud be as easy as possible to debug. Ideally a person that knows the english language and does not code should be able to figure at least the context of the logic.

Fancy things are coo if everyone understand those, people change in projects, logic needs to be rewritten. Would it be nice to just know what and where to change instead of figuring out how it works and why this way in the first place ?

You will tel me that Kenneth E. Iverson, John Backus in 1930s and 60s, Uncle Bob more recently, already wrote about this countless time. You would be right !

What i would like to emphasize is not just write code that explains itself but explains itself and is udnerstandable by another a human beeing.

Piotr Kowalski