Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

That's a good one.

Another measure I use for code quality is: how afraid am I of breaking something when I make changes? This is where typing and tests shine.



Typing and tests definitely help, but nothing works better than having well-factored, decoupled code, so a change in one place doesn’t impact the rest of the code base in unexpected ways. Unfortunately I don’t know of a good way to do that outside of experience + vigilance.


Good abstractions + asserts + minimal assumptions everywhere in the code (also called refactoring-resistant code)


Unexpected is an interesting word. This probably means consistency is important, because expected in one codebase could be unexpected in another.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: