Why I Like Pair (or More) Programming…

As I prepare my apprentices for their interviews, I reminded them about the possibility of pair programming interviews.  While I wasn’t exposed to pair programming early in my career, once I finally was exposed to it, I was beyond thrilled!  These are some of the reasons why I enjoy pair programming.

Learning From Others

I really enjoy learning from others.  I never know for sure who I may end up pairing with, but I go into each pairing session with an open mind.  Whether we’re talking through the problem or writing the code, we may come in with different programming styles.  However, talking with each other and compromising along the way – I actually enjoy the whole process.  I am also open to pairing with developers of various skill levels – from novice/hobbyist to advanced.  In my past experiences, I have found that the communication and patience between the pair tends to determine what makes a pair successful, moreso than skill levels.  We come from different backgrounds, and I like watching how they come together.

Writing Better Code

With multiple eyes on the code, we can spot ways to improve each other’s code, or at least talk about the different approaches we would take.  In pairing, there has to be a lot of communication about the code, which means talking through complex issues and making sure not to approach a problem blindly.  By having these conversations and clearly conveying our thoughts, we have a better chance of writing better code than if we coded by ourselves separately.

More Than Two?

As the title suggests, I have been in programming situations where we’ve been a group bigger than 2.  My fondest memories go back to working on a team of 5 devs with 1 machine that happened to be remotely located.  Each one of us had different backgrounds – web developers, firmware/hardware/low-level developers, database developers, math genius, etc.  Quinting with those 4 devs taught me how to be a better backseat driver and how to play off of each others’ strengths and personalities.  Unfortunately, it didn’t break me of my inner editor – I still would point out missing semi-colons and mismatched curly braces.

Overall, I am thankful that I’ve had the pairing (and more!) experiences I’ve had so far.  So much learning, so many more avenues to think about while writing code, and so much desire to pair with others and have fun!

Special shoutout to my friends at LeanDog for giving me solid experience quinting with such an awesome team!

LeanDog

One thought on “Why I Like Pair (or More) Programming…

  1. John Strobel says:

    I’m not in disagreement with anything said above, but I’m curious to know your opinion on how pairing (or more) impacts speed. With two developers producing a single deliverable, doesn’t that necessarily impact the rate at which a feature is completed? As a follow-up, do you think the speed matters?

    In my experience, a good team will have a ton of interaction, a ton of ad-hoc pairing by nature of being a good team. I’m not sure we’ve ever paired for more than an hour at a time, though, unless someone was well and truly stuck. This allowed multiple features to be progressed while still providing the support structure and learning opportunities you mentioned above.

Leave a Reply

Your email address will not be published. Required fields are marked *