Pair Programming

Pair program effectively — driver-navigator roles, switching frequency, and communication patterns.

RahulRachhoya Updated

File contents

Pair Programming

Roles

  • Driver: writes the code. Focused on the tactical: syntax, API calls, current line
  • Navigator: thinks ahead. Focused on the strategic: design, edge cases, test coverage, what comes next
  • Switch roles every 15-30 minutes (use a timer)

Communication

  • Navigator speaks first: "next we need to handle the error case"
  • Driver confirms: "ok, I'll add a try-catch"
  • Both ask questions: "why this approach?" "what about X?"
  • No silent coding — narrate your thinking

Benefits

  • Fewer bugs (real-time code review)
  • Knowledge sharing across the team
  • Better design decisions (two perspectives)
  • Fewer distractions (accountability)
  • Faster onboarding for new team members

Rules

  • Both are equally responsible for the code
  • Navigator is not a backseat driver — give high-level guidance, not keystroke-level commands
  • Take breaks — pairing is mentally intense (Pomodoro: 25min on, 5min off)
  • Switch pairs regularly to spread knowledge
  • Not every task needs pairing — use it for complex or critical work

RahulRachhoya/auto-skill-mcp/tree/main/src/auto_skill_mcp/skill_data/pair-programming commit d1345657a1

Frequently asked questions

npx skillmds@latest add rahulrachhoya/pair-programming