Code layout matters

Apr 25, 2013 02:27

Saw a quote "If you can't explain it simply, you don't understand it well enough." from A.Einstein, and decided to write this post about relation between clear thinking and the simple, elegant, structure it creates.
Over a decade now I've been finding bugs with high success rate essentially by looking how beautiful code layout is. If the idea of the code structure is clear in coder's mind, it probably gets written down in that clear structure. Where the layout is messy, or inconsistent, coder him/herself has probably had hard time understanding what (s)he is doing. If coder doesn't understand what (s)he is doing, there's certainly bug or five there.
Had I chosen career in academic world, this would be the area I'd want to research. (Err... even now I want, but can't, damn you choices in life)

If you can't make code beautiful, you don't understand it well enough.
Previous post Next post
Up