the programmer language,

Dec 06, 2014
Slow programming might be too slow

Recently I've been reading about slow programming, and seen people arguing that programming is not about typing.

Let's review that claim more closely.

Our current programming environments are text-based, for better or worse. Thus, our primary way of expressing ideas as code is through text manipulation. On the other hand, the most efficient interface to a computer is the keyboard, which in turn, by leveraging very advanced text editors, becomes the ultimate tool to manipulate text.

The reason the keyboard is the most advanced input device we've come up with is that every other device that came after completely disregarded muscle memory. Mice require thoughtful eye-hand coordination -- too complex a task to make use of our dumb muscle-based L1 caches. Even voice dictation (which I'm using right now to write this) is still way too slow and error prone.

What we can learn from music

We've established that keyboards provide us with the fastest way to manipulate text in a computer, but what does that have to do with programming? Isn't programming about applying hard thought and creativity to solve problems?

The act of programming is really encoding our thoughts into code using a language. It is no different from composing music, where what we hear in our heads needs to be translated to music notation -- an extraneous, cryptic written language -- to be read and performed at a later time by an interpreter.

More often than not, composers don't just come up with a piece of music and write it in its entirety before even playing it once. Much like programmers, they explore ideas by trying them out with the help of an interpreter (almost invariably themselves) to see and evaluate the shape of their composition as it evolves.

In doing so, they benefit from a quick feedback loop in the same way that a Clojure developer benefits from having a REPL in which to toy around and explore unknown APIs. The speed of that feedback loop is very well constrained by her typing skills.

A composer with poor piano skills will be not only slower, but flat-out limited in the quality and expressiveness of her composition. However, a composer with an excellent piano technique well enjoy a much quicker feedback loop, enabling her brain to quickly explore and dismiss ideas and reach thought patterns that would be otherwise unreachable.

Is fast touch-typing a must?

In conclusion, as long as keyboards are the most effective interface to manipulate text, and as long as that is the way we program (by manipulating text), fast touch-typing is absolutely necessary (but obviously not sufficient) to be a competent programmer.