Ping-Pong Programming

Henric Trotzig
3 min readAug 25, 2014

When I wake up in the morning, my teammates go to bed. When they go to work, I’m getting ready for dinner. Am I just a stereotype of a programmer, living the Jolt Cola dream? Nope. I’m just 5,447.08 miles away from San Francisco, across the Atlantic Ocean. I’m a remote worker.

Remote working has its pros and cons. It’s a privilege to live in a time where remote working is even possible. It’s a blessing not having to commute to work every day. But it’s painful to miss out on the face-to-face social interaction with your team members. However, this post is not about discussing pros and cons, it’s about something as hands-on as table tennis.

When I first started working remote, I wanted to make sure I was still an integrated member of the team. I didn’t want to become the person who only worked on well-specified, isolated, features. I didn’t want to feel alone. Lucky for me, I’ve got world-class collaborators on my team. Without thinking too much about it, me being remote made us do things differently. For once, we wouldn’t let anyone work completely alone on a feature. And we started finishing each others work, similar to when close friends finish each other’s sentences. Work that I did during my work day was picked up by my team members in San Francisco when they came to the office. The result of their work benefitted me when I woke up the next day. After a while, a pattern started emerging, and we even started referring to it by name: Ping-Pong Programming.

Ping-Pong Programming is when two or more engineers team up and bounce commits back and forth between each other. Your computer is your paddle, the code you write is the ball. (The net in my case is the Atlantic Ocean, but that’s not too important).

In short, this is how you play Ping-Pong Programming:

  • Player A writes code in one or more commits
  • Player B reviews those commits
  • (optional) Player B cleans up the commits
  • Player B merges the commits
  • Player B writes code on top of player A’s commits
  • … and so forth

The key to Ping-pong Programming is that you merge someone else’s commits, not your own. By doing so, you are forced to understand the code that you merge and vouch for its quality. You are also more likely to write code in small, incremental steps — since you need to make sure that it’s easy to understand and simple to work on top of. This style of collaborating promotes better communication among the team. You are not only responsible for understanding your own code and the features you work on. You also have to explain to others what you are doing, how you are doing it, and why you are doing it.

Ping-Pong Programming fits perfectly if someone on your team is time-shifted. Instead of complaining about timezone differences, you can embrace them. Become comfortable with the fact that when you leave the office, someone else will continue where you left off, working towards the same goal as you. Coming in to the office (or café/kitchen/sofa as in my case) with your work from yesterday all cleaned up and merged is a great feeling.

Caveats

Before I started working remote, I had been working at the Causes/Brigade HQ for about two years. I already had an on-site presence at the company. For me, this is key. I wouldn’t be able to work from afar now if I hadn’t been on-site before. The friendships I made wouldn’t be the same if those connections were formed over chat.

My teammate Joe and his wife Sam came to Sweden this summer to hang out
My teammate Shane visiting me in Stockholm

--

--