Download - How does pair programming work?
[Pair Programming]
Ghezal Ahmad “Zia”
3/24/2011 1Pair Programming
Forward
This presentation, represent a research result which is
prepared by Stuart Wray at Royal School of Signals,
Blandford, United kingdom, that defines why pair
programming sometimes brings benefit and sometimes
does not.
3/24/2011
2
Pair Programming
Outline
3/24/2011Pair Programming
3
Motivation
Pair Programming approach
Characteristic of pair programming
Advantages of Pair Programming
Conclusion
What Pair Programming is?
3/24/2011Pair Programming
4
Pair programming is a style of programming in which two
programmers work side by side at one computer, continually
collaborating on the same analysis, design, algorithm,
implementation, code, or test.
Motivation
3/24/2011Pair Programming
5
• Driver
– “Driver” has control of the keyboard and focuses on the
immediate task of coding.
• Navigator
– Tactical defects (syntax errors, calls to wrong method)
– Strategic error (heading down wrong path)
How does Pair Programming work?Pair programming approach
3/24/2011Pair Programming
6
Why Pair programming is sometimes useful and
sometimes doesn't?
3/24/2011Pair Programming
7
NavigatorDriver
Pair programming approach
How does Pair Programming work?
http://www.golfhotelwhiskey.com/what-airlines-can-teach-general-aviation-pilots/
Pair…Pair programming approach
3/24/2011
8
Pair Programming
http://www.jupiterimages.com/Image/royaltyFree/77636342
Pair…Pair programming approach
3/24/2011
9
Pair Programming
http://fachisthers.com/template_archives.asp?chosenYear=2008&chosenMonth=4
Pair…Pair programming approach
3/24/2011
10
Pair Programming
3/24/2011Pair Programming
11
Pair Pressure
– Keep each other on task and focused
– Don’t want to let partner down
Pair Negotiation
– Have shared goals and plans
– Bring different prior experiences to the task
– Different access to task relevant information
– Must negotiate a common shared of action
Characteristics of Pair Programming
Abstraction
[1]
Characteristics of Pair Programming
3/24/2011
12
Pair Programming
Pair Programming would drive me crazy.
Characteristics of Pair Programming
3/24/2011
13
Pair Programming
Two head is better than oneCharacteristics of Pair Programming
3/24/2011
14
Pair Programming
Immediate Objections
3/24/2011Pair Programming
15
• Why use two programmers to do the work that one
can do?
• Programmers prefer to work in isolation.
• Egos and disagreements about implementation will
hinder development.
Characteristics of Pair Programming
Objection 1: Why use two programmers to do the
work that one can do?
Characteristics of Pair Programming
3/24/2011
16
Pair Programming
3/24/2011Pair Programming
17
• Brainstorming– Produce higher quality designs.
– Catch design flaws early on, different approaches to the solution.
• Problem Isolation
– Easier for two to find and resolve a problem.
– Both thinking about problem differently.
• Focus
– Keep each other on track.
– Different experience levels
Objection 1Characteristics of Pair Programming
Objection 2: Programming is solitary work..
Characteristics of Pair Programming
3/24/2011
18
Pair Programming
Objection 2
3/24/2011Pair Programming
19
• Common assumption
– Traditionally taught and practiced this way
• Takes some adjustment
– Most are initially skeptical
• Teamwork
_ Pairs produced higher quality code
Characteristics of Pair Programming
Objection 3: Egos and disagreements will
hinder development.
Characteristics of Pair Programming
3/24/2011
20
Pair Programming
Objection 3
3/24/2011Pair Programming
21
• Occasionally an issue.
– Rarely have dysfunctional pairs
– Disagreements can be easily resolved by a third
party
Characteristics of Pair Programming
Advantages
3/24/2011Pair Programming
22
• Learn more about the system and software development.
• Problems are solved quicker.
• Coding Standards followed more closely.
• Team communication and cohesiveness.
• Enhanced productivity
• Shorter and better code
• Less bugs
• Sharing of knowledge
Advantage of Pair Programming
Important term
Is a method of programming that has come from the
agile methodology of Extreme Programming (XP) .
Better distribution of inner knowledge
More team spirit
A good idea to rotate pairs
Two pair with refresh eyes
Pair Programming is very effective:
In term of time
In term of quality
Conclusion
3/24/2011
23
Pair Programming
Thanks for your attention!
3/24/2011 Pair Programming 24
24
References
3/24/2011Pair Programming
25
[1] Cockburn and Williams. The Costs and Benefits of Pair Programming. [http://collaboration.csc.ncsu.edu/laurie/Papers/XPSardinia.PDF]
[2] Jensen, Randal. A Pair Programming Experience.CrossTalk. Mar, 2003. [http://www.stsc.hill.af.mil/crosstalk/2003/03/jensen.html]
[3] Pair Programming. Cunningham & Cunningham, Inc. Jan. 15, 2006.[http://www.c2.com/cgi/wiki?PairProgramming]
[4] Williams, Kessler, Cunningham. Strengthening the Case for Pair-Programming. [http://www.cs.utah.edu/~lwilliam/Papers/ieeeSoftware.PDF]
[5] http://collaboration.csc.ncsu.edu/laurie
Question?
3/24/2011
26
Pair Programming
YOU WILL NEVER WORK ALONE NOW!
3/24/2011 Pair Programming 27
27