We already talked about what’s “Pair Programming” and different types of it, but is it really as good as they say?
New employees can get up to speed much faster by pairing with an experienced team member. Under the pair programming model, new-hires have a constant role model to work under.
Before the pair settles on an approach to a particular problem; they discuss, evaluate, and talk through any trade-offs involved. Problems are picked up on earlier and potential bugs are identified by two people instead of one. Solutions are evaluated up-front rather than after they’ve already been implemented.
Pair programming provides a process for sharing knowledge and context that is built into your everyday workflow. Pairing with a more senior developer is the best way for junior developers to improve their skills. Senior developers can also learn new things when pairing with a more junior developer. Everyone's an expert in something, and everyone has something they can teach.
Harder to Procrastinate
Working as a team means you can’t stop and check your E-mail, Slack or WhatsApp for any desired distraction.
Increase Employee Satisfaction
Coding can be a lonely pursuit when you are behind a computer alone and told to produce features. On the other hand, coding together may bring employees closer as they share experiences and have more subjects to talk about. When other people understand what you’re up to you’ll have more in common.
The majority of the time programmers spend at the job isn’t actually writing new code. The majority of the time we spend at the keyboard isn’t typing it’s strategizing, debugging, testing, etc.
Having two programmers at one workstation means that teams are twice as likely to know how to fix a problem as soon as they encounter it. For example, if someone on the team knows the solution to an error, debugging can take seconds.
Better than Code Reviews?
While it’s challenging to find somebody to review your code because people may not want to look at another’s code and understand their reasoning just for the sake of checking its quality. With pairing, it is like having somebody review your code instantly and regularly. It is a higher form of code reviews. If one sees problems with the other’s code, then it can be instantly corrected (this can also save a lot of time). You also have fewer chances of having bugs written into your code.
Don’t Overdo It
Forcing people to spend all day together isn’t sensible and they may well end up hating each other.
More coffee and pairing up is not always the answer. When you’re tired and stressed you might not be communicating properly.
Simple Tasks can be complicated
It can be hard for two programmers to stay interested in a very simple bug fix or a straightforward feature to implement (not to mention it can be expensive to put two programmers on that task). Keep in mind that sometimes, having a pair partner can boost morale when working on a simple task.
For more complex code it might be a distraction trying to pair together. Sometimes sitting down and explaining the problem can be more beneficial. Formally sitting down together and writing code line by line could actually be distracting.
In conclusion, the impact on productivity and output is very positive with pair programming, as pairs generally have more design substitutes than programmers.