Pair programming vs Mob programming
Pair Programming
Pair Programming consists of 2 programmers where one being a navigator and one being a driver. This pair works together on one story at a time, where one programmer is a navigator and the other is the driver.
Mob Programming
Mobbing is similar to pairing, except that there is one driver and many navigators. In mob programming, everyone works on one story while one person drives and everyone else navigates. Mob programming is best used when only one person has experience in something and needs to catch the team up, or when the team is learning something new together. Otherwise, pair programming is a better approach.
Roles
There are two roles, as you’ve no doubt already noticed in pair and mob programming. These roles are the navigator and the driver. It is important that the people in these roles remember that they are a team and are working together to complete a task. We’ll break down what these roles entail below.
Driver
The driver is the person who is at the keyboard, typing the solution. As the driver, you type what the navigator says and don’t “run away”. Running away is the term used for a driver who stops listening to their navigator and just starts typing their own solution. It can be hard not to do this as the driver. Sometimes because the navigator doesn’t know what to do, sometimes because the navigator is going too fast and it’s hard to keep up. This is where it’s important to signal to overwhelm. This can be done in many ways, such as simply lifting your hands from the keyboard, simply saying “let’s slow down” or any other signal agreed upon between navigators and drivers.
Navigator
As the navigator, it’s your job to explain the solution and help your driver to code it. Navigator roles are best taken by the more experienced programmer per solution. As a navigator, you want to make sure to find the level of your driver. Don’t direct experienced programmers as if they are novices and don’t direct novices as if they know (or should know) everything. It is also important to pay attention to cues from your driver. If you notice them feeling overwhelmed, then know that it’s time to adjust your approach or take a break.