By Therese Hansen | July 2, 2008
First of all: What is beauty?
For beauty includes three conditions, “integrity” or “perfection,” since those things which are impaired are by the very fact ugly; due “proportion” or “harmony”; and lastly, “brightness” or “clarity,” whence things are called beautiful which have a bright color.
— Thomas Aquinas, Summa Theologica.
- Integrity: Integrity is about fitness for purpose – how well does the solution fit the problem?
- Proportionality: Good structure with perfect relation between parts of a system.
- Clarity: Simplicity and clarity of code.
After the talk Kresten Krab did an interview with Marcel Molina, Glenn Vanderburg and Chad Fowler about the beauty of code and they concluded that it is something worth striving towards. Not because you want to be an artist but because it is good for your clients.
You can see the interview here:
The idea is that making beautiful code has practical value and is not just an egotistical desire on the part of the programmer who wants to be an artist. Beauty is used as an indicator of quality. Even when the beauty is in the source code and not visible to the customer of a software product it is still desirable in terms of the trade-off between cost of creation and cost of ownership.
Kent Beck talks about common code smells and the smell of ugly code can be very useful, but can the notion of beauty be of practical use as well?
Can we build on the thinking of Marcel Molina and Thomas Aquinas and get nice practical rules of thumb about beautiful code?JAOO | Tags: beautiful code, beauty, Chad Fowler, Glenn Vanderburg, Kent Beck, Kresten Krab, Marcel Molina, Thomas Aquinas | 4 Comments »