The Hardest Thing About Pair Programming
is learning when to back down.
I’ve been formally studying software development for six days. The same goes for the people I’ve been pairing with. In theory, we should both not really know what’s going on. But I’ve been getting into a lot of situations where I feel very strongly that one solution is correct and my partner feels very strongly that another solution is correct. How do we solve this?
If it’s a small enough part of the program, I like to test it out. I’ll make a new Sublime Text file or open an IRB session to see whether our code behaves the way we want it to. Experimentation really helps cement the concepts for me, but I think my partners sometimes feel that this approach wastes time, and that it means I don’t trust their knowledge. I suppose they’re right about that part; I don’t trust their knowledge, but I don’t trust my own either. I hope my partners know that when I want to make sure their suggested code does what they says it will do, it’s not that I think they’re stupid. It’s just that I know we’re all beginners, and also that writing out the code and testing it makes it way more likely that I’ll actually remember it.
But what if the disagreement is about something bigger? What if it’s not just a few lines I can put into IRB? Often my partner and I disagree about the overall structure our program. Each of us feels that doing it the other way will lead to hours of wasted labor. Which means I have two options:
- Back down. This ends the confrontation and allows us to get back to coding, but if it turns out I was right, it means we may write lines and lines of useless code. If I never assert myself, it defeats the purpose of pair programming. I should be offering ideas too, not just acting as a sounding board for my partner. Also, as a feminist*, I would feel uncomfortable making this my default strategy. Women are taught from birth to acquiesce to others’ wishes instead of asserting themselves**. Since my partners so far have all been male, I think there is a gender dynamic at play that encourages both of us to defer to the man’s opinion. This is an inclination that I actively try to counter.
- Stand my ground. If my partner defers to me and I turn out to be wrong, we’ll still end up going down the wrong path. But my partners usually don’t defer until after quite a bit of back-and-forth, which puts us both on the defensive. Choosing to stand my ground often means choosing to have an argument. If I persuade my partner to let me pursue my idea and it doesn’t work, I will feel (perhaps rightly, perhaps wrongly) that they resent me. The more we argue, the less our partnership feels like a safe space.
I think the solution is for both my partners and myself to stop thinking about things in terms of who’s right and who’s wrong. We should be on a journey together, not competing to see who can solve the most puzzles. I try to ask my partners a lot of open-ended questions at the beginning of the process; “How should we handle this?” “Where should this part go?” and such things. I should try to continue that dynamic throughout the process. I hope that this signals to my partner that we are exploring together (and doesn’t read as deference), and I hope that they respond by asking similar questions of me. The teachers at Launch have made it clear that being able to work with others is just as important as technical know-how. I think pair programming may prove to be the most difficult and most valuable part of my Launch education.
*I have a feeling I’ll be starting a lot of sentences this way.
**And men are taught that women should defer to their opinions. Shut up, you know it’s true.
Email me when Eve Asher publishes or recommends stories