January 26, 2019
Pair Programming is a great way to write better code and disseminate knowledge through the team at the same time. Counterintuitively, pairing has been shown to increase, not decrease, overall team velocity long-term – even though engineering man-hours are higher overall.
Pair Programming is a coding technique involving two engineers. One will be the driver, who writes the code and navigates the IDE. The other will be the navigator, who will review the code as it is written. The engineers sit together and discuss their thought process and approach as they code, and they switch off often to allow both to drive.
Pair Programming works because it encourages thoughtfulness in code so that effective decisions are made.
There’s two things you can do:
As a team leader, I strongly recommend that my engineers pair as much as possible. Although there’s often initial friction to the idea, developers consistently report higher satisfaction with their work, the end result tends to be much better, and it helps increase your bus number (in other words, it disseminates knowledge, which is a risk point in team leadership). Ideally, you should spend 50%+ of your coding time in a paired session.