I have two modes for writing software. When I’m in the right mode for the work at hand, I’m extremely effective. In the wrong mode, my productivity grinds to a halt. It took me far too long to realize this.
The first is “playing” mode.
This is when I’m toying around with a new idea, seeing if it has legs. I try to build a working prototype as quickly as possible, then iteratively grow that by alternating between layering on functionality and vicious refactoring. In this mode, it helps to work on the exciting things first and follow the fun, cutting corners when possible.
The second is “planning” mode.
In this mode, the software already has some mass, some inertia. There is already an established way of doing things, and perturbing the existing order too much would break a stable system and disrupt others already familiar with the codebase.
I call this planning mode because “coding” actually starts with a plan of action, thinking through what I want to do, and listing out exactly what changes I need to make in what order, down to the file and function. This is done when I have thought through every change I want to make, in a way that prioritizes the preservervation of the existing codebase as much as possible.
Both modes can be fun. When playing, the fun is about getting something done in the quickest, hackiest way possible, often surprising myself in the process. When planning, the fun is in the satisfaction of solving a puzzle and seeing everything slot neatly into place.
Content © 2006-2019 Rusty Klophaus