Start Over Coder

053: Pair Programming

01.24.2018 - By Start Over CoderPlay

Download our free app to listen on your phone

Download on the App StoreGet it on Google Play

Pair programming is a productive way to write code with other people, and often used as an interview tool as well. I’ve been incorporating pairing into my study plan recently, and here’s what I learned! What is pair programming? It's two people writing code together, and sharing one computer to do it. One person is the driver: their hands are on the keyboard and they are talking through the code they write as they write it. The other person is the navigator: the navigator takes a 'big picture' approach and reviews the code as it's being written, stopping to ask questions or offer guidance based on what the driver writes. During the pair programming session, you would periodically switch so that each person sits in both roles several times. The main idea is that with two heads working together, the code will be better than if just one person was working alone. Here are the biggest benefits and lessons I've found so far in my pair programming experiences: You see another way to approach solving problems. It could be better, it could be worse, or it could simply be different. Regardless, you can learn something by seeing multiple ways of doing something! It's easy to put pressure on yourself to start writing code even if you haven't thought it all the way through yet, just because there's another person there watching. Instead, take advantage of a second mind and work together to create a full plan before actually writing any code. Pairing is a unique experience that you can only practice with another person! Make the effort, it's worth it. Since you're may work more slowly as a pair, take any environment obstacles out of the way before starting: dedicate a set amount of time and make sure you have a good internet connection (and backup plans). Regardless of who is the more experienced coder, it's beneficial for both people to work in both positions—the driver and the navigator. Make sure you switch off regularly! If you're learning how to code (on your own or otherwise), I would highly recommend working some pair programming time into the mix! It might be intimidating to start, but these benefits and more make it worth it in the end. And if you don't live in a busy area or can't get yourself to a place where other people are up for pairing, don't discount the option of finding a pair programming partner online. My experience was great—I'll include some links to open communities where you can look for a pairing partner in the list below. Show Links: What is pair programming? YouTube video Codebuddies public Slack Code Newbie public Slack Codeshare lets you work on code together online Codewars gives you coding challenges - great for pairing   Thoughts on this episode? Leave a comment at startovercoder.com/053 or tweet me @startovercoder.

More episodes from Start Over Coder