Pros and Cons of Pair Programming

Ritesh Kumar
3 min readAug 10, 2017

During my college days there was a course in which we were to take up a Software Engineering project in a team of two persons. This was for the first time I came across pair programming but at that time I never realized there is actually a ‘term’ for this. Pair programming is a technique in switch two programmers work on the same computer at the same time: however only one of them does the actual coding while the other checks each line of code as it is written. Every once in a while the two switch places and keep on coding. The one who codes is called anchor and the other navigator.From my experience I would like to jot down pros and cons of pair programming.

Pros :

  1. Two different perspectives on a problem : When you are coding in pair it might happen that you are not able to think from all the perspectives and any other point of view is all that you require. You can look at a problem from two different perspectives and find a solution much faster and easily. However since both the programmers are side-by-side there has to be some care taken so that both aren’t always thinking the same thing.
  2. Quickly able to spot the bugs and errors : Small syntactical errors and bugs are caught easily right then and there . Though it seems very small issue it can save you a lot of debug time and frustration which will in turn increase your productivity.
  3. Knowledge pooling : One can also learn a lot from their partner. Combining knowledge of your and your teammate will surely give a boost to your performance as well as productivity. Instead of taking help from your mentors and textbooks , you can learn things easily from your partner.
  4. Reduced dependency : Suppose you are working on a large project and there is some developer in your team who has a knowledge of a particular module of the project but due to some unavoidable circumstances that guy is not available. The project will certainly come to a halt as there is no other guy who has the knowledge of that module. Had it been the case in which the guy would have paired with someone in your team the project would not come to standstill and hence the dependency gets reduced.
  5. Less stress and better concentration : Working in a team of two reduces stress. While you become the navigator your mind and body gets some time to relax which can improve your concentration and eases out your mental fatigue.

Cons :

  1. Decrease in productivity : It happens with some people that they can’t work or concentrate while someone is watching them or interrupting them. Working in a team of two generally becomes a social affair and you end up wasting time on talks , chit chats and fun.
  2. Skill disparity : This is the number one potential problem. If the partners are of completely different skill levels, you might have one programmer doing all the work or constantly tutoring the other. This is ok if you want to set up a teacher-student relationship or are introducing a new programmer to your system, but if not, it can defeat the entire purpose of pair-programming.
  3. Friction and ego : There can be scenarios where yours thought will conflict your teammate’s. The egos of two developers might collide which can put you to standstill and ruin the relationship amongst team mates.

I myself find pair programming advantageous and more productive not only for coders but also for projects they are working on. But it is the matter of choice.One might feel that solo programming is better than programming in pair. But my advice would be before choosing any of the former options try to weigh their pros and cons considering your project requirements.

Till then Happy Coding !!!

--

--