This term seems to be quite in use in English-speaking communities. I'm curious what it is? Is it like two students code together on a single PC or what? Is this organization (whatever it is) is only used in US?
Pair programming is one of the main practices in Extreme Programming (XP). It does literally mean two people working on one computer, usually one at the keyboard (often referred to as the driver) and a partner (referred to as the passenger or shotgun). It is reputed to improve productivity and the quality of the generated code as well as enforce group ownership of the code - another tenent of XP.
When in doubt, ask Wikipedia: Pair Programming. The general idea is to have one person writing code while the other scans for mistakes and cohesiveness.
http://en.wikipedia.org/wiki/Pair_programming
Pair programming is a software development technique in which two programmers work together at one keyboard. One types in code while the other reviews each line of code as it's typed in. The person typing is called the driver. The person reviewing the code is called the observer[1] or navigator. The two programmers switch roles frequently (possibly every 30 minutes).
While reviewing, the observer also considers the strategic direction of the work, coming up with ideas for improvements and likely future problems to address. This frees the driver to focus all of his or her attention on the "tactical" aspects of completing the current task, using the observer as a safety net and guide.
An extension of Pair Programming sometimes used by practitioners of Test Driven Development is Ping Pong Pairing.
Ping Pong Pairing works something like:
- Write a failing test (developer A)
- Implement code that makes the test pass then (optionally) Refactor (developer B)
- Write a failing test (developer B)
- Implement code that makes the test pass then (optionally) Refactor (developer A)
- and so on...
One of the benefits of Ping Pong Pairing is that it's tough for either developer to sleep very long ;-)
Paired programming is when two developer work on the same story card sharing a single computer and keyboard. It is considered an extreme programming practice. Extreme programming takes something positive, in this case a code review, and takes it to the extreme. The benefits beyond the continuous code review are as follows:
- Improved quality: A pair of active programmers working on the same story card will complete the card with less defects
- Improved productivity: a pair is less likely to be slowed down if not outright blocked when solving a problem. Furthermore, it is harder to take an email or web vacation when you are working with a partner ... you don't want to let the partner down. You will solve the problem with a cleaner design and less lines of code when working as a pair
- Eliminate silos of knowledge: With rotating pairs, you will learn application and domain business knowledge across the team. The team is less likely to be blocked because Sue when on vacation and no one else knows her code.
- Knowledge Transfer: Rotating pairs teach new skills (engineering and domain) to each other as they work together. The level of the team will rise for everyone and the knowledge propagates through the team.
- Team self selects: The team learns one anther's skills and will quickly weed out someone that is not performing.