A Pair Programming Trial in The CS1 Lab

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

A Pair Programming Trial in the CS1 Lab

Shamim Khan1, Lydia Ray2, Aurelia Smith3, Angkul Kongmunvattana4


TSYS School of Computer Science
Columbus State University
Columbus, GA 31907, USA
{ khan_shamim, ray_lydia, 3smith_aurelia, 4kongmunvattana_angkul}@colstate.edu
1 2

Abstract—The benefits of pair programming have been In recent years, a number of approaches has been
recognized for some time now. Numerous attempts have tried to address the issues of both low CS1
been made to introduce pair programming in the
classroom to improve student learning and enrollment and success rates. These include the use
performance. A trial introduction of this method in the of more attractive interactive programming languages
introductory Computer Science (CS1) lab-based class is and IDEs (e.g., Alice, Greenfoot and Python), media
reported. The noticeable improvement found in student
computation [3], robotics [4], computer games [5] as
performance is in agreement with most previous
studies. This study also explores student perception of well as pair programming. This paper reports a trial
this collaborative approach to learning, and some of the pair programming approach in the CS1 lab
administrative issues. class over several semesters at CSU’s School of
Keywords – pair programming; collaborative learning; Computer Science.
pair formation; driver-navigator model; student
perception II. PAIR PROGRAMMING IN INDUSTRY
AND THE CLASSROOM
The origin of pair programming is in eXtreme
I. INTRODUCTION
Programming (XP) - an emerging software
Motivation generated in the freshman year plays an development methodology intended to improve
important role in undergraduate student retention and productivity. In software industry pair programming,
progression. According to one study, 60% of students production code is written collaboratively with a
who abandon their course of study do so in their first partner, where two programmers sit side by side and
year [1] at the university. Student failure and share a computer. Anecdotal evidence suggests that
withdrawal rates in the introductory Computer two programmers can be more than twice as fast and
Science (CS1) course are unacceptably high in most can think of more than twice as many solutions than
institutions – more than 30% in the US according to a the two working on their own. Also, constant code
nationwide survey [2]. At Columbus State University reviews, an inherent part of pair programming, results
(CSU), the average student success rate in CS1 over in higher defect prevention and removal leading to a
the last five years (2004 – 2009) has been around higher quality product. As reported in a survey of
53%. professional pair programmers by [6], all participants
agreed that they had more confidence in their
Student success in CS1 is decided largely by their solution when doing pair programming than when
success in learning problem solving using computer they worked alone. About 96% of them agreed that
programming. Student performance in classroom they enjoyed their job more when programming in
exercises and assignments shows a large number of pairs. In an experiment at the University of Utah [6],
students struggling when it comes to understanding students in two courses - Collaborative Development
core computing concepts and essential features of of Active Server Pages (20 juniors and seniors) and
programming languages. Lack of success leads to Software Engineering ( 41 juniors and seniors) were
students’ loss of confidence and many simply give divided into two groups – paired and non-paired.
up. Reportedly, students in pairs passed 15% more of
instructor’s test cases compared with those working The students involved in this study were all
individually. freshmen, with most of them in their first semester at
the university. The traditional approach of asking
Ever since the establishment of pair programming as students to find their partners to form a pair was not
a useful technique in professional software adopted since the students hardly knew each other,
development, educators have been trying to especially during the first week of the semester. This
understand its potential benefits in introductory decision was later borne out by our survey results
computing courses. In 2002, a study was conducted (see below) which indicated possible difficulty faced
on the effectiveness of pair programming on by students in this approach. Instead of forming pairs
freshman learning at the University of Santa Cruz [7] randomly, we decided to form pairs based on
showing improvements in the quality of completed individual programming experiences. To assist the
programming assignments as well as the time spent pairing of students, they were asked to do a self-
in completing these assignments. A number of evaluation of their programming skill in a survey
studies thereafter have also shown the positive effect carried out on the first day of the semester. An
of pair programming on student learning and the attempt was made in this process to pair students with
quality of code produced by students [8,9,10,11]. comparable programming experience and skills by
However, at least one study [12] demonstrated some avoiding strong-weak and weak-weak pairs as far as
negative aspects of pair programming. According to possible. This was based on the idea that putting two
this study, students who used pair programming did weak students together might put these students at a
not write significantly better programs than students relative disadvantage compared with pairs with a
who worked alone. Most students were of the opinion different mix. Strong-weak pairing also was avoided
that the key to success in pair programming was to with the expectation that such a pairing would result
get a good partner. in the more skilled student dominating over his/her
weaker partner, thus making it difficult to maintain
III. PAIR PROGRAMMING AT CSU the spirit of learning through equal participation.
In an effort to improve student retention and
progression rates in Computer Science, as well as to B. The Pair programming Model
attract non-Computer Science majors to this Students in each pair worked collaboratively on each
discipline, it was decided to investigate pair assignment. They were asked to assume driver and
programming as a teaching methodology. As part of a navigator roles and switch them regularly. The driver
trial involving the CS1 lab class, students were paired controlled the mouse and keyboard to enter the code,
together during the first week of the semester. compile and run it. The navigator actively examined
the driver’s work for syntax and logic errors, and any
A. Formation of Pairs deficiencies in the design, or for possible design-
A student’s motivation to work collaboratively implementation mismatch. He/she also looked up
depends to a large extent on compatibility with resources and thought of alternatives. The driver and
his/her partner. Accordingly, a good deal of attention navigator would switch roles every 20 minutes or so,
has been focused on the strategies for forming pairs. ensuring they worked as a team and obtained the
The following pair-formation methods have been benefit of acting in each role. The pair would
suggested in the National Center for Women & continue working in this manner until the
Information Technology (NCWIT) pair programming assignment was complete.
programming-in-a-box resources [13]:
The issue of assessing work done by students in a
- Pairs based on levels of programming experience pair is a difficult one. The simplest approach is to
- Pairs formed randomly award both students the same grade, although ideally,
- Pairs formed by students with instructor in a group effort, individuals should receive grades
guidance based on the amount of effort they put in. Assessing
individual contribution, for example, through
interviews, can be time consuming and difficult to
manage. We adopted an approach built partially on shows that, based on available data, student
peer review. Students in a pair were required to performance in classes with pair programming is
submit their work jointly but respond to a few peer significantly better, with DWF rates in the range 7%-
review questions independently. Both students in a 45%, compared with performance in classes where
pair received the grade for their joint effort after it students worked on their own, with these rates in the
had been weighted by mutual peer evaluation. The range 20%-57%.
evaluation questions used are given in Table 1 below.
TABLE II. STUDENT DWF GRADE PERCENTAGES IN
Students had to submit answers to these questions CLASSES WITH AND WITHOUT PAIR PROGRAMMING
with each assignment work using a 5-point Likert
Semester DWF (%)
scale, with 5 corresponding to strongly agree, 3 to Fall, 2006 57%
neutral, and 1 to strongly disagree. Each student’s Spring, 2007 20%
grade was scaled by the average of his/her partner’s Fall, 2007 30%
responses to these three questions. Spring, 2008 47%
Fall, 2008 27%
TABLE I. PEER EVALUATION QUESTIONS Spring, 2009a 45%
Fall, 2009 (section 1)a 7%
1. My partner did his/her fair share of the work Fall, 2009 (section 2)a 21%
2. My partner was cooperative a. Classes offered with pair programming

3. My partner was willing to switch driver-


navigator roles To assess student perception of the benefits or
otherwise of pair programming, and issues related to
its compliance and administration, an exit survey of
IV. RESEARCH OUTCOMES the class was conducted. Questions in this survey
The two broad objectives of our investigation were: were also answered using a 5-point Likert scale. The
(1) to find out if pair programming is beneficial to issues evaluated and the corresponding questions in
students and (2) to assess student perception of pair the questionnaire are shown below in Table 3.
programming.
Based on a survey done on 59 students belonging to
To ascertain the impact of pair programming on three separate classes over two semesters, 24% of
student performance, course grades earned by them admitted to splitting the work and doing their
students in three CS1 classes taught with pair own share independently. This amounted to
programming over two semesters during 2009-2010 practicing cooperation rather than collaboration,
were compared with the grades from classes offered which is the central to pair programming. There was
without this approach over the previous five also the tendency among some students (22%) to do
semesters during 2006-2008 (the CS1course did not the same work independently and submit the better
have a separate lab-based component before 2006). one – once again violating the principle of
It was assumed that improved grades would indicate collaboration. These feedback data pointed to a
an overall improvement in students’ understanding of degree of student resistance to full compliance with
the material covered in the class as well as their the pair programming model. With peer evaluation,
programming skills. although only 10% admitted they rated their partner
too highly, this contrasted with our own observation
Table 2 below shows the percentage of students of individual performance and the rating they
failing to obtain a satisfactory grade. The DWF value received from their partners. We found that students
represents the fraction of the total number of students tended to rate their partners highly or very highly (4
who were unable to obtain an A, B or C grade, and it or 5 out of 5) quite consistently, even when it was the
includes students who withdrew from the course late weaker partner.
in the semester, presumably after failing to keep up
with the class. The last three rows of this table
correspond to data from the three groups of students
taught with pair programming. Figures in table 2
TABLE III. STUDENT SURVEY ISSUES AND negatively, with 72% expressing the opinion that
CORRESPONDING QUESTIONS
students, not instructors, should choose their partners.
Issues Questions Interestingly, although pairs were formed by
Benefits Working in pair for doing instructors, only 10% thought they had the wrong
programming assignments in class
partner and 59% expressed the opinion that not
helped me get a better grade
knowing others in the class well enough would make
Experience I enjoyed pair programming
it difficult for them to select a partner.
There should be pair programming
for programming assignments in
other courses V. CONCLUSIONS
Working in a pair hindered my Previous studies have highlighted the potential
progress benefits of pair programming, which include
I prefer doing programming - Better learning due to peer-tutoring
assignments in class on my own Students feel more at ease, and thus can
Opinion on My partner was cooperative concentrate better on the subject matter,
partner My partner did his/her fair share of
with a peer tutor rather than a professional
work
teacher [14].
I had the right partner
- Better utilization of time
Execution In my pair, we split the assignment
exercises and worked on separate Students don’t need to wait for instructor
parts help if their partner can help.
In my pair, we both worked on the - Positive effects of legitimized collaboration
same exercises and submitted the Collaborative work, particularly during the
better of the two. school years, is treated with suspicion, and
often regarded as cheating. Pair
Peer evaluation In rating my partner I gave him/her programming gives students early
more credit than deserved
collaborative work experience, fostering the
In rating my partner I gave him/her
development of teamwork and
the credit he/she deserved
communication skills that are highly valued
Opinion on the It is possible to work collaboratively
driver- with one person as the driver and the in both the academia and the job market.
navigator other person as the navigator - Reduced workload for instructors
model Pair programming reduces assessment
Pair formation Students should be allowed to choose workload significantly for instructors,
strategy their own pair programming partner leaving more time for creative efforts to
The professor should choose the improve teaching.
partner for everyone
Partners should be chosen randomly Data on grades available to us so far, and as
Not knowing anyone well enough in presented in this paper, suggest an overall
the class may be a problem in
improvement in student performance with pair
choosing your own partner
programming. But students’ own opinion on this
approach is somewhat mixed. There appears to be a
Overall, student attitude to pair programming was
certain level of reluctance among students to accept
positive. In terms of the benefit gained from pair
its beneficial effects. There is anecdotal evidence that
programming, students thought it helped with their
this dissatisfaction with pair programming might be
understanding of the assignments given (74%) and
linked to students not being used to collaborative
with improving their programming skill (76%). The
work in the past, and their natural resistance to being
use of pair programming in other future courses was
forced into a different mindset. Elements of the pair
supported by 71% of the respondents. Opinion was
programming model that attempt to impose a
more divided on the driver-navigator model, with just
structure on students’ work habit appear to be
64% expressing their confidence in it. The method
particularly unpopular – the best example of which is
followed for forming pairs was viewed broadly
the requirement of switching driver-navigator roles at [8] C. McDowell, L. Werner, H. Bullock, and J. Fernald, “The
effects of pair-programming on performance in an
regular intervals. More than a third of the students introductory programming course,” Proceedings of the 33rd
did not view the driver-navigator-based model SIGCSE Technical Symposium on Computer Science
Education, pp. 38-52, February 27 – March 3, Cincinnati,
favorably. There also appears to be a strong feeling USA, 2002.
among students against the instructor forming student
pairs. Instructor intervention only for students unable [9] L. Williams, E. Wiebe, K.Yang, M. Ferzli and C. Miller, “In
support of pair programming in the introductory computer
to form pairs by themselves may help achieve a science course,” Computer Science Education, Vol. 12, Issue
higher student satisfaction level crucial for the 3, 2002, pp. 197-212.
successful administration of pair programming in the
class room. [10] B. Simon, and B. Hanks, “First-year students’ impressions of
pair programming in CS1,” Journal on Educational
Resources in Computing (JERIC), Vol. 7, Issue 4, pp. 1-28.
Students’ learning experience in the introductory 2008.
[11] G. Braught, L. M .Eby, and T. Wahls, “The effects of pair-
Computer Science course is crucial in forming their programming on individual programming skill,” ACM
first impression of the discipline. Early success can SIGCSE Bulletin, Vol. 40, Issue 1, pp. 200-204, 2008.
lead to a lasting impact on student motivation. The [12] J. Somervell, "Pair Programming: Not for Everyone?" 2006
International Conference on Frontiers in Education:
findings of this study lend further credence to the Computer Science and Computer Engineering (FECS'06),
strategy of using pair programming to help improve Las Vegas, USA, June 26-29, 2006.
student performance and hence student retention and [13] National Center for Women & Information Technology
Resources website. [Online], “Pair Programming-in-a-Box:
progression in Computer Science. But it also brings The Power of Collaborative Learning”, 2010, Available:
to light the existence of underlying student apathy to http://www.ncwit.org/resources.res.box.pair.html
collaborative learning. A successful implementation [14] S. W. Ehly and S. C. Larsen, “ Peer Tutoring for
Individualized Instruction,” Boston: Allyn and Bacon, Inc.,
of pair programming would depend on addressing 1980.
administrative issues such as pair formation and
assessment taking students concerns into account.

REFERENCES
[1] E. W. G. Clua, “A Game Oriented Approach for Teaching
Computer Science,” SBC 2008 Workshop on Computing
Education, Belem do Para, Brazil, July 12-18, 2008.
[2] H.Roumani, “Design Guidelines for the lab Component of
Objects-first CS1,” Proc. Thirty-third SIGCSE Technical
Symposium on Computer Science Education, D. Knox, Ed.
ACM, New York, 2002, pp. 222–226.
[3] L. Ray, S. Khan, W. Summers and B.Wright, “Media
Computation: An Audio-Visual Approach to Teaching
Computer Programming,” International Journal for
Knowledge, Science and Technology, Vol.1, Issue 2, pp. 93-
101, 2010.
[4] M. Koski, J. Kurhila, and T. Pasanen, “Why using robots to
teach computer science can be successful theoretical
reflection to andragogy and minimalism,” Proc. 8th
International Conference on Computing Education Research,
Koli, Finland, November 13-16, 2008.
[5] A. M. Phelps, C. A. Egert and J. D. Bayliss, "Games in the
Classroom: Using Games as a Motivator for Studying
Computing: Part 1, " IEEE Multimedia, Vol. 16, Issue 2, pp.
4-8, Apr.-June 2009.
[6] L. Williams and R. R. Kessler, "Experimenting with
Industry's 'Pair-Programming' Model in the Computer
Science Classroom," Computer Science Education, Vol. 11,
Issue 1, pp. 7-20, 2001.
[7] J. Bevan, L. Werner,C. McDowell, “Guidelines for the use of
pair programming in a freshman programming class,”
Proceedings of the 15th Conference on Software Engineering
Education and Training (CSEET'02), Covington, USA,
February 25-27, 2002.

You might also like