Wednesday, March 29, 2006

Code Kata

Sometime back I had read about code kata from the blog of Dave, the well-known author of the book "The Pragmatic Programmer Book" & its series. He introduces a set of practice exercises needed to improve our coding skill in any language or even our thinking about a problem in a business domain. They stretch your thinking and coding abilities. Here is an excerpt from his blog.




What’s a Code Kata?


As a group, software developers don’t practice enough. Most of our learning takes place on the job, which means that most of our mistakes get made there as well. Other creative professions practice: artists carry a sketchpad, musicians play technical pieces, poets constantly rewrite works. In karate, where the aim is to learn to spar or fight, most of a student’s time is spent learning and refining basic moves. The more formal of these exercises are called kata.

To help developers get the same benefits from practicing, we’re putting together a series of code kata: simple, artificial exercises which let us experiment and learn without the pressure of a production environment. Our suggestions for doing the kata are:

  • find a place and time where you won’t be interrupted

  • focus on the essential elements of the kata

  • remember to look for feedback for every major decision

  • if it helps, keep a journal of your progress

  • have discussion groups with other developers, but try to have completed the kata first


There are no right or wrong answers in these kata: the benefit comes from the process, not from the result.

Follow the original blog at http://blogs.pragprog.com/cgi-bin/pragdave.cgi/Practices/Kata. So far he has added around 21 code kata.



If you want to discuss kata, there’s a mailing list here, and a wiki here. However, remember that the point of the kata is not arriving at a correct answer. The point is the stuff you learn along the way.

This is not just reading, so spare some time to spend & reap benefits! Also share any of your personal Code Kata with others.

No comments:

Recommended Blog Posts