Pair Programming

Zea Lingard
5 min readMay 31, 2021

It’s 2021, after a year plus in quarantine many tech companies have been forced to adapt their workforce to a remote model where possible. This includes Shopify, Amazon, Facebook and many more tech giants. For an increasing number of companies a remote workforce is here to stay. Global Workplace Analytics estimates that 25–30% of the workforce will work from home for several days a week by the end of 2021.

If you’re in the tech space it’s time to get very familiar with pair programming. Whether you’re a software educator, hiring manager, student or hopeful job applicant, chances are pair programming will become an important part of career growth. Switching to a remote model in the tech industry means we need to be cautious of working in a silo. Some potential risks of working in a silo are:

  • Efforts not focused on real company issues.
  • Time and resources wasted.
  • Duplication of efforts.
  • Inefficiency of investment dollars.
  • Increased likelihood of errors.
  • Breakdown of communication.
  • Decrease in employee morale.

Before we get started, what exactly is pair programming you may ask?
By definition:

“Pair programming is an agile software development technique in which two programmers work together at one workstation. One, the driver, writes code while the other, the observer or navigator,[1] reviews each line of code as it is typed in. The two programmers switch roles frequently.” — Wikipedia.

The benefits of pair programming help to breakdown common challenges of teams accidentally working in a silo. Here are some added benefits of pair programming:

  • Shared new knowledge.
  • Avoid duplication of efforts.
  • Be introduced to new concepts.
  • Positive collaboration — come to a better solution together.
  • Decreased likelihood of errors.
  • Better communication, even after the PP session.
  • Enhanced team morale.

I first hand got to experience the benefits of pair programming as a student at Lighthouse Labs Web Development Bootcamp. If you’re new to coding and are extremely intimidated by the thought of coding in front of literally anyone else, don’t worry we’ve all been there! For my first pair programming (PP) session I was partnered with a peer who was very outspoken and confident in class, my ego did not want to openly share that I did not confidently know how to write a function, let alone in real time, in-front of someone I had just met. In this case, my partner was happy to take the driver seat as I watched how they approached the problem. It was humbling for both of us to see them make lots of mistakes and take it in their stride. This broke the ice, and as a navigator allowed me to participate, being brave enough to suggest possible solutions even if they may not work the first time. Although there’s the likely possibility your solutions may fail epicly in real-time PP, this provides the perfect opportunity to learn first hand by doing while collaboratively problem solving, it’s a win-win. After practicing pair programming many times now, I value seeing the logic pan out behind how my partner would approach complex questions.

Now enough with the personal stories, what tools do you need to pair program? The tooling for pair programing really depends on the situation you’re in and what device you’re using. If you’re a job applicant, chances are the interviewers will have their own system with an Integrated Development Environment (IDE), that you will be invited to. The environment you’re invited to for a tech interview may look something like HackerRank’s:

If you’re a student or employee you may get to choose your own pair programming tooling. Below are some options:

1. Microsoft Live Share Extension Pack

When your prefered IDE is Visual Studios Code, this is an excellent option. Your teammates get instant, secure access to your code. No configuration needed! You can edit and debug in real time, on the same editor in real-time. It has an easy one step installation and shareable link to invite participants. You can choose read/write access only and share the in-editor terminal for easy testing. Just remember to end their session when you’re done as your partner will have access to all your files open in that session!

2. tmux terminal

Tmux (in combination with ssh) enables a number of terminals to be created, accessed, and controlled from a single screen. Contents of the windows will be synchronized between all clients. But each client can decide individually which window’s content should be shown at the moment.

source: https://www.hamvocke.com/blog/remote-pair-programming-with-tmux/

3. Motepair by Atom

For all our Atom IDE fans, there’s a lag free remote pair program for you! It has similar features to the other PP programs where you can edit, save and delete in real-time with another developer. However, Motepair’s connection is not encrypted so they advise you to use another pair program if you have an issue with that.

4. Teletype for Atom

Teletype for Atom was created by GitHub. If you’re working on a top secret project this is a great option as Teletype uses WebRTC to encrypt all communication between collaborators.

5. Tuple

Tuple is a Mac-only remote pair programming tool — lots of big companies use it. Tuple has great UI and useability. Their customer service is also excellent if you run into any issues. It has no lag and excellent audio. (Good news for Linux users, Tuple is coming to you soon!)

How to approach your first Pair Programming session?

Now that you’ve decided on the tooling you will use to Pair Program, I recommend just jumping straight into it. The best way to learn something is by doing it!

1. Grab a friend, colleague, or your mom (literally anyone that will listen) and jump on one of the suggested pair programs above. Send an invite link to the participant.

2. Find a test ‘question’. Example interview questions can be found at HackerRank.

3. Pseudo code (out loud): Start writing out your logic and talking out loud about what you are writing down. Before you start jumping into functions, loops, conditionals or any other tool from your kit, it’s a great idea to outline your intentions. This shows your thought process and allows the viewer to be more involved in the process. As you proceed to build out how the code is going to run, this provides an opportunity to test against your initial logic & potentially be challenged by the other participant.

4. If it’s not an interview setting, directly ask your partner how they may have approached the problem differently & why. This will help to develop your skill-set further, as they say in coding there’s always more than one road to the solution.

This seems like a great place to end this post! Don’t be afraid to lean on your peers and openly discuss your logic. Practicing coding together can be fun and provide beneficial solutions in the workplace, as well as for dev students and potential job candidates. Whether you like pair programming or not, with the way many software companies are moving to remote, as a developer chances are you will come across pair programming and be required to partake. Why not get ahead of the game and start learning the ropes now, to get comfortable writing code in-front of others & articulating your solution!

Sources:

https://www.apollotechnical.com/statistics-on-remote-workers/

https://en.wikipedia.org/wiki/Pair_programming

https://en.wikipedia.org/wiki/Whiteboarding

www.makeitinua.com/posts/13-best-tools-for-remote-pair-programming-in-2020

https://www.hamvocke.com/blog/remote-pair-programming-with-tmux/

--

--