Upload
jon-jagger
View
1.579
Download
0
Embed Size (px)
Citation preview
pair programming
twitter : @JonJaggeremail : [email protected]
blog : http://jonjagger.blogspot.co.uk/charity : http://cyber-dojo.org
2
a seldom questioned view of programming - a view which this book will spend a great deal of time questioning. That view is that programming is an individual activity...
3
Written 1969 Published 1971
Silver Anniversary 1994 Golden Anniversary 2019
longest continuously in-print book on software
development?
4
devs who say they work alone don't
5
pairing and getting unstuck
6
rubber-duck debugging
https://en.wikipedia.org/wiki/Rubber_duck_debugging
7
silenttalking
images are representative only
8
lifesize cardboard cutouts!
9
pairing and perseverance
10
what 's the longest lived
bug?
11
queen termites can live
50 years!
12
time
6-12 months0 months
RIP
13
if you're going through hell, keep going
14
pairing and productivity
15
in my experience, pair programming is
more productive than dividing the work between
two programmers and then integrating the
results
16
programmers admit to working harder and
smarter on programs because they do not want
to let their partner down
17
pairs spent about 15% more time on the program than the individuals*
the resulting code has about 15% fewer defects
the pairs consistently implemented the same functionality in fewer lines of code
most of the programmers enjoyed programming
collaboratively
http://collaboration.csc.ncsu.edu/laurie/Papers/ieeeSoftware.PDF
strengthening the case for pair programming
Laurie WilliamsRobert Kessler
Ward CunninghamRon Jeffries
18
An experiment by Temple University Professor Nosek studied 15 full-time, experienced programmers
working for 45 minutes on a challenging problem, important to their organization, in their own
environment, and with their own equipment. Five worked individually, ten worked collaboratively in five pairs. Conditions and materials used were the same for both the experimental (team) and control
(individual) groups.
Nosek, J. T. (1998). The Case for Collaborative Programming. Communications of the ACM. March 1998: 105-108.
19
All the teams outperformed the individual programmers, enjoyed the problem-solving
process more, and had greater confidence in their solutions... producing better algorithms
and code in less time (40%)
Results statistically significant using two-sidedt-test.
20
if pairing increases productivity
why is it rare?
21
pairing is rare because working solo is common!
22
"locking" occurs whenever a situation
creates an environment favorable for
maintaining that situation...
locking occurs in all sorts of systems...
especially... social
23
? different keyboards ? different editors ? table design ? room layout ? number of computers ? tools ? individual assessments ? languages ? expertise
24
most people resist transitioning to pair programming – it involves breaking old habits and being more communicative and collaborative than we’ve been conditioned to be
25
pairs spent about 15% more time on the program than the individuals*
the resulting code has about 15% fewer defects
the pairs consistently implemented the same functionality in fewer lines of code
most of the programmers enjoyed programming
collaboratively
for the first assignment pairs took 60% more programmer hours to complete the assignment
*
26
transitioning to pairing is not easy
give it at least 3 weeks
it gets worse before it gets better
27
XP
28
name the XP values
4 in edition 1 5 in edition 2
29
Simplicity Communication Feedback Courage! Trust
30
pairing and communication
31
pair programming works for XP because it encourages communication
XP is a communal software development discipline.
32
we believe pair programming is an integral part
of XP
33
pairing doesn't really work if you don't talk!
34
"at first I found it hard
to verbalize my thoughts"
35
pairing and courage
36
if people program solo they are more likely to make mistakes, more likely to
overdesign, more likely to blow off the other practises, particularly under pressure
37
under stress, people revert to earlier behaviour, no matter how badly that behaviour has worked in the past
38
programmers admit to working harder and
smarter on programs because they do not want
to let their partner down
39
Studies of Independence and Submission to Group Pressure.
A Minority of One Against a Unanimous Majority
Solomon Asch
Psychological Monographs, 7, Series No. 416, 1956.
40
7 confederates 1 subject
https://en.wikipedia.org/wiki/Asch_conformity_experiments
41
18 trialsin trial 1 and trial 2 the
7 confederates and the subject gave the obviously right answer
in the remaining 16 trials the 7 confederates gave the wrong
answer 12 times
42
75% of subjects gave incorrect answer in at least 1 trial
subject conformed to the incorrect answer in all 12 trials
36% of the time
43
variationpresence of 1 true confederate decreased subjects conformity
to the incorrect answer by 75%
44
pairing and feedback
45
it is a well-known psychological principle that in order to maximize the rate of learning, the subject must be fed back information on how well or poorly he is doing
46
the average adult learns very little if
left to his own devices
47
we are all lousy self evaluators
48
?% of high school seniors believe their leadership skills are below average
49
2% of high school seniors believe their leadership skills are below average
50
51
I am the World's leading expert
on the Dunning-Kruger effect!
52
pairing and
learning
53
the requirement to develop capability cannot be met adequately by a single person. We learn much faster and much better with the active cooperation of others
54
learning from success
55
learning from failure only has meaning when we know what we mean by success
Kevlin Henney
56
i have not failed i've just found
1000 ways that won't work
Thomas Edison
57
success == invent an incandescent light bulb that lasts
one hour
58
recording pairs clock faces
59
60
picking pairs randomly!
helps reduce locking
61
pairing and risk
helps reduce truck/bus number
62
pairing and risk
also known as the lottery number
63
pairing and interruptionspairs are very resistant to interruptions
64
pairing and interviewing
teamwork characteristics... cannot be determined if you interview ... one at a time.
65
pairing and practice
I felt it was unwise to allow players to practice by
themselves. Always I wanted them to be interacting with
their teammates.
66
pairing and ping-pong
http://c2.com/cgi/wiki?PairProgrammingPingPongPattern
67
pairing and refactoring
Wibble * p = new WIbble(); if (p == NULL) ....
68
if driver always writes definitions before use suggest
writing use before definition
pairing and observing
69
navigator reads ALPHA in code/comment but
driver says BETA when describing ALPHA
pairing and observing
70
triple programming
71
the pair results were also more consistent, while the individuals varied more about the mean
pairing and consistency
72
pairing and scaling
having more than nine members requires too much coordination
Scrum Guide
having more than nine pairs requires too much coordination
What about...
73
repairing
in http://cyber-dojo.org pairs easily cope with repairing every 5 minutes!
74
pairing and becoming a
team
75
if egoless programming is used, everyone in the group will have the opportunity to examine the work of everyone else at some time, thereby tending to prevent the establishment of strong hierarchy p72
76
widespread use of pair programming involves a
cultural shift in values of the organization - away from
individual and toward team recognition and goals
thanks for listening
twitter : @JonJaggeremail : [email protected]
blog : http://jonjagger.blogspot.co.uk/charity : http://cyber-dojo.org