Harnessing the Power of Pair Programming
February 20, 2019
Two Programmers Are Better Than One
As technology advances and customer needs become increasingly more refined, tech developers are under more pressure than ever to take their programming methodologies to the next level. Collaboration has become vital to improving the quality of the product as well as creating a better work environment. One way that tech developers such as CoreLogic are adding collaboration into their framework is with pair programming.
What Is Pair Programming?
Pair programming is a form of Extreme Programming (XP) that emphasizes collaboration and continuous feedback. Programmers typically sit side-by-side at a large desk containing a computer and a second monitor each with a mouse and keyboard. The programmers are working in the same integrated development environment and either developer can assume control at any time. As you might expect, this set-up requires a lot of collaboration. The programmers are typically in constant communication, bouncing ideas off each other to solve problems and create solutions as they develop.
Since 2014, CoreLogic has made pair programming the backbone of our tech development framework. CoreLogic has delivered several new products to the real-estate and insurance markets leveraging the XP framework. XP is utilized at several office locations across the U.S. and is actively growing additional XP teams. Pair programming requires developers who are social and good communicators in addition to being great coders. We try to rotate pairs daily to promote shared context and use PairTrix to randomly assigns pairs at the beginning of the work day, though managers stay flexible and may sometimes allow a pair to stay together to finish up a task they had almost completed the day before. Mixing up the pairs helps programmers put their talent to work across all parts of the project’s code base and prevents anyone from falling into a rut.
Better, Faster Results
Working in such a collaborate environment promotes greater focus – not only for the pair but for the entire team. We take lots of breaks – ping pong being our favorite – where pairs can play against each other or grab another pair to compete against. We co-locate balanced teams, where the Technical Product Manager (TPM), the UX/UI Designer, and the developers are in the same immediate area. This reduces the need for teleconferences and meetings as developers can get questions answered in real-time. Pair programming also helps keep the flow of work moving forward. Lone programmers are often tempted to find a perfect solution or spend hours going down a rabbit hole, often forgetting why they even started down this path. Pair programmers at CoreLogic help each other timebox their tasks and look for the easiest solution now, because the requirements and circumstances will likely change in the future.
CoreLogic has also seen a substantial increase in the quality of the code with the implementation of pair programming along with test-driven development (TDD). Code created by pairs, joining forces to problem-solve as they go, has significantly fewer defects than code created by programmers left solely to their own devices. TDD encourages the pair to think about the intended behavior of the code by writing a failing test first, and then writing the simplest code possible to make the test pass. Refactoring is not a bad word. In fact, refactoring is something we expect our developers to spend a significant amount of time on. As the team learns more and gets user feedback, there are always opportunities to rethink and refactor, which makes the product more resilient and flexible.
Many people assume that putting two programmers at the same work station will halve your productivity, but it’s quite the opposite, as productivity actually increases. A pair can typically get 6 to 7 hours of productive coding per day versus a developer typical at most enterprises who gets maybe 3 hours of productive coding done due to all the distractions, meetings and teleconferences. The team starts at the same time in the morning, breaks for lunch at the same time, and leaves the office at the same time. The result is a pace this is predictable and sustainable. The pairs thrive on delivering features, producing business value and leaving the office with a sense of accomplishment every day. That means reduced production costs, faster feedback and a quicker time to market.
Happiness Through Teamwork
Perhaps the most notable benefit to pair programming is job satisfaction. The common stereotypical image of a programmer is often a loner wearing headphones and working in isolation, completely cut off from the rest of the world. This ultimately proves to be an extremely unfulfilling and a dull experience, particularly for Millennials. Modern programmers entering the market place a higher emphasis on collaboration and social interaction. Pair programmers feel more engaged in their work and prouder of the results. This creates a more sustainable and rewarding work environment.
So the age-old aphorism “two heads are better then one” has never been more true than in software development. Pair programming is revolutionizing the digital sphere and helping to build the next generation of cutting-edge technology that will shape the future.
Written by Glenn Kronschnabl, Executive, Software Engineering