For the next few weeks, we will be experimenting a bit by having guests doing the String Calculator kata in different languages. I did it originally in Ruby, and we have Erlang, Scala, Clojure and Python coming. I’ll be contacting Roy Osherove, who sparked this kata, to do it in C# for us.
Watching the same solution in multiple languages can help us notice similarities in the styles, in the syntax and in the approach to solving the problem. For languages from a different family than your usual one, make sure you notice things that aren’t quite clear and take some time to look into what they are. Erlang, for example, relies heavily on pattern matching to find the code to execute. I remember when I was fooling around a bit with Erlang, and the ‘pattern matching as a side-effect of binding’ (my words) idea clicked for me; it was amazing, and I started to look to see if there were appropriate ways to apply this idea in my day-to-day language (Ruby).
Enjoy the series, and, if you would like to be a guest katacaster, please contact me, and we can see what we can work out.