Programmer Batting Order
Jeremy •
Programming •
A programmer that I work with did something today that got me thinking about a twist on pair programming. He swept through the application we are working on and cleaned up some little things that have irked him lately. It's clear there are benefits in being a "cleanup" programmer once in a while, but are there benefits to being a "leadoff" programmer? What if we paired up on each task, but not at the same computer and instead in complementary roles -- a leadoff programmer and a cleanup programmer.
The way I see it, the main benefit of pair programming is having two sets of eyeballs on any given piece of code. I've tried pair programming in the past with varying levels of success. There's no doubt that the resulting code is of a higher quality, but it's been my experience that most people have different styles of getting stuff done; and trying to get stuff done at the same computer with another person can be tiring and frustrating. So let's pair up on tasks, but in a specific batting order rather than at the same terminal.
In a baseball batting order there are 9 positions. The first position is called the "leadoff," the fourth is the "cleanup hitter," and the ninth is the "last." In the spirit of pair programming I'm going to skip all but the first and fourth. Here's a brief description:
- The "leadoff" batter is usually the fastest base-runner. He bats more often than anyone else and needs to have a high on base percentage so that he can score when the power hitters are up
- The "cleanup" hitter (the fourth position in baseball) is usually a highly talented hitter whose job is to "clean" the bases by driving home the base-runners to score runs.
These two roles could work really well for programming. Put a programmer in the leadoff role that is a fast coder. A person that can whip through a task and get it to a functionally complete state. Then, put someone in the cleanup position that can review the task, tighten up the code, and push it out to production. Might work well. You get two sets of eyeballs on the code and the programmers can work in their own way focusing on their role for each task.
I think it would be very beneficial and refreshing to swap roles on different tasks, but I wonder if different programmers would ultimately settle into one position or another. On a given team, I would guess the lineup would become fairly stable after a while.
With a team of more than two programmers, what if you set an order for a given set of tasks and rotated through the line-up for each task? Let's say you had a team of 3 programmers. On the first task, the first batter would be the leadoff and the second the cleanup. On the second task, the third programmer would leadoff and the first would cleanup, and so on... It might be interesting.
What do you think?
