Pair Programming is a development approach where two engineers collaborate on a single development effort at a single setup (virtual or not).
Pairing implies that the responsibilities are equally shared, not split. This might mean two people take different roles or that they alternate between "driving".
Pair Programming following Llewellyn’s strong-style pairing
This style mirrors that of a driver with a navigator in a car, where the high level instructions come from the navigator and the implementation being done by driver.
This style of programming is all about increasing communication and collaboration, building the ability to verbally communicate code and editor commands.
The driver needs to ensure the solution is out of the navigators head by facilitating code input and challenging design decisions after the solution has been codified or when the navigator is confused and unable to navigate.
The navigator has two main jobs to manage the big picture details so the driver can stay focused on the code they are typing: Giving the next instruction to the driver the instant they are ready to implement it, and talk in the highest level of abstraction the driver can understand.
Pair Programming following Test Driven Development
Pair Programming can also lead itself to test driven development where two developers (A and B) work such that;Â
Pairing implies that the responsibilities are equally shared, not split. This might mean two people take different roles or that they alternate between "driving".
Pair Programming following Llewellyn’s strong-style pairing
This style mirrors that of a driver with a navigator in a car, where the high level instructions come from the navigator and the implementation being done by driver.
This style of programming is all about increasing communication and collaboration, building the ability to verbally communicate code and editor commands.
The driver needs to ensure the solution is out of the navigators head by facilitating code input and challenging design decisions after the solution has been codified or when the navigator is confused and unable to navigate.
The navigator has two main jobs to manage the big picture details so the driver can stay focused on the code they are typing: Giving the next instruction to the driver the instant they are ready to implement it, and talk in the highest level of abstraction the driver can understand.
Pair Programming following Test Driven Development
Pair Programming can also lead itself to test driven development where two developers (A and B) work such that;Â
- A writes a new test and sees that it fails.Â
- B implements the code needed to pass the test.Â
- B writes the next test and sees that it fails.Â
- A implements the code needed to pass the test.Â
Using this approach, refactoring is done whenever the need arises by whoever is driving. Pairing using these methods can be done by anybody in the dev / test teams.