Thursday, March 31, 2005

Simple is beautiful

Chats with Sailaja ( one of my friends ) are always very interesting. Not only you can converse on wide array of topics but you also get to learn a whole lot of new things. In one of those interesting discussions that I have with her, she sent me this nice little poem.

He drew a circle that shut me out
--Heretic, rebel, a thing to flout.
But Love and I had the wit to win:
We drew a circle that took him in!

"Outwitted" by Edwin Markham (complete poem)

This poem struck me. What a simple way to express such profound thoughts. The beauty of this poetry lies in its simplicity. Greatness lies in expressing complex things in a simple manner and not the other way around. And I actually think that this principle is very much applicable to software development.

Some of recent applications, that I have come across, have used dozens of classes to do something that should not have taken more than two. Use of patterns is good and is encouraged, but that has led programmers trying to crunch in whatever patterns they have learnt over the years in to one small little application. If not designing is a crime, over engineering is a bigger crime.

Test First Design is one of the activities suggested by XP. It is said that TFD helps in catching bugs, building up regression testing suites etc. Sure it does, but in my view, it achieves one greater thing, it helps restraining developers from over engineering their applications.

There is some good literature advocating simplicity:
* Refactoring to Patterns is a book by Joshua Kerievsky

No comments: