DEV Community

Discussion on: How would you define high quality code?

Collapse
 
almostconverge profile image
Peter Ellis

I would look at the following criteria:

  1. When I make a change, how confident am I that the change will do exactly what I expect it to?
  2. Also, how long do I need to look for the right place to make the change?
  3. Are simple things simple to implement?
  4. How long do I need to look at the codebase to figure out "the system", i.e. how everything is organised?

These all sort of tie together, something with no unit tests for example is likely to fail on 1, whereas something with extensive but brittle unit tests will fail on 3.