There have been many literatures on comparison of the art of programmings to other professions. Few authors compare it to the art of building a house and few to the art of gardening. Some say its like chorus of music and for few its like writing a book.

Having no experience in any of those arts and only a little of seven years in coding, I can neither deny or agree on those comparisons. But having written few short essays these days, I do think that the art of writing does come closest to art of coding.

What makes me say that you ask?

For one both are structured. In writing, you divide things in to chapters and introductions and conclusions depending upon what you are writing. In coding we divide things in to modules, services, repositories depending upon what we are coding for.

Both are optimised for reader. No matter how good a story you have in mind, If its not put forth in readable way then is of no use. Same goes with programming, we optimise it for readability so that future programmers make sense of it.

Both needs polishing after initial draft. In programming we call it as refactoring and in writing we call it as editing. This step is crucial to turn an ordinary raw ore to a beautiful diamond.

Both are optimised for clarity and simplicity. There is a saying in programming that less you write a code to solve a problem, less bugs you create. Unclear and complex code or writing is a hurdle for readability.

Both can be elegant. There are times when I see a piece of code and marvel at its artistry. And same goes for writing. Remember it is not just an act of solving a problem or writing a story, It is about how gracefully you do it. Both are about “Craftsmanship”.

Being good at one skill will definitely complement in being better at the other. To those who have not tried either one of them, I strongly suggest them to do. Knowing one makes learning the other easier šŸ˜‰