Josh Thompson     about     blog     projects

Typing for Programmers

Article Table of Contents

If you had to distill my ability to bring value to those around me, it would be “Josh types good”.

I can press these magical little keys on this little metal box here, and make these words come out.

If you’re reading these words, you don’t care how these words actually got on this page. You don’t care if I used speech-to-text, transcription, hunt-and-pecked, or if my keyboard layout is QWERTY, Dvorak , or Colemak.

All that matters is that I can express reasonable ideas reasonably well. (Or, as I prefer, unreasonable ideas, reasonably well.)

You, too, probably spend a bit of your time behind a keyboard.

I’ve already spent time trying to improve my typing speed. After ill-fated attempts at converting myself to using the Colemak keyboard layout, but I gave up, except I kept my CAPS LOCK key mapped to DELETE.

That was a reasonable position to find myself, except now I’m getting into this whole “programming” thing. That means I have to familiarize myself with that part of my keyboard I’ve so far avoided, like:

[] {} |\\| #{'word_that_means_something'} && |other| arcane.keys

Don’t forget your symbols!

! @ # $ % & * ( ) - _ = + < > \ ~ \

I ultimately need to be able to use every single one of those keys without thinking about it, without looking at the keyboard, and without looking at what I’m typing to verify that it’s correct.

(For example, if you’re reading documentation or code on one part of your screen, typing something into some other program, you cannot be looking at what you’re typing and what you’re supposed to be typing simultaneously.)

How have I learned to type all these crazy symbols? #

Two methods:

  • Typing.io
  • Changed my passwords

Typing.io #

  • typing.io bills itself as “Typing Practice for Programmers”

You can pick a language you want to learn (like Ruby, Python, C++, etc) and then presents you with real live code, that you type along with.

Typing.io doesn’t solve everything, though, because there are still common code combinations that are hard to learn without lots of repetition.

An example from the Ruby track: Have you ever used the | key? NO!

So, that brings us to method number 2:

Changing my passwords #

Change commonly used passwords to require hard-to-type code snippets.

I first got creative with changing my passwords after reading How a Password Changed My Life. I’d remind myself to get up early, (when that was hard, I reminded myself to go to bed early).

I cannot say that I’ve transformed my life through creative passwords, but I stumbled across using them to improve my typing.

I’ve got two passwords that I often type:

  1. My computer password, because I’ve got my computer set to sleep if there’s no activity for five minutes (it requires a password upon waking up)
  2. 1Password Password Manager. Any time I want to log into a system that requires a password (so, about fifteen different systems during the normal workday), I have the password saved to 1Password, and if it has been inactive for five minutes, it locks itself.

So, if I change both passwords to something incorporating difficult-to-use key combinations, I am using hard-to-remember keys, over and over and over

For both systems, I create unique passwords that require me to get good with different pieces of code.

In the past, I’ve used it to train the #, %, && symbols, as well as [] and {}. I’m now comfortable with #{} and [&&]. Soon, I’ll rotate them again to incorporate more “sticky” keys that I struggle with.

As I get deeper into my studies, anytime I encounter a difficult key combination (like hitting = right after my pinky is otherwise engaged with a ' or | key) I jot it down, to use next time I update my passwords.

If you’re getting into Ruby, here’s some potential passwords to play with. Please don’t use these actual passwords, but sub in meaningful-but-random words where appropriate.

  • @word.map do { |c| c[0] }
  • <%= variable_name_here %>
  • index[0][1]
  • /\A*regex(.|,)\z/i
  • hashes = { curley_braces_everywhere }

Best of luck to you!