Pair Programming in CS Education: An Implementation Guide

8:05 AM on August 12, 2021 | Product News programming

There is a wide spectrum of collaborative coding practices ranging from individual assignments, to divide-and-conquer programming (a student favorite) to pair programming.

Pair programming is the practice of two programmers sitting side-by-side on one computer—one acting as the “driver” who controls the mouse and keyboard and the other acting as the “navigator” who watches for errors and makes suggestions—switching roles regularly.

Watch our Pair Programming On-Demand Webinar

As you go from one end of the spectrum to the other, the amount of time spent actively collaborating increases—which is why pair programming, where you collaborate with a partner the entire time you’re programming, is at the far end.

The spectrum of coding on which Pair Programming sits

Pair programming actually comes from a professional development style called extreme programming (XP) which has found many benefits of the practice, most notably in terms of code quality. “Pair programming was later adopted as a promising practice in higher education settings because of the benefits of increased retention of students continuing their study of computing, increases in programming confidence in students, and reductions in the ‘confidence gap’ between female and male students” (Simon, et al. 2019, p. 828).

Education Research supporting Pair Programming:

As this practice became more widely adopted in education settings, additional learning benefits were found. “Almost all studies from [systematic literature reviews] claim evidence that pair programming leads to success in beginning programming courses” (Simon, et al. 2019, p. 830). Also, students report “greater satisfaction and enjoyment when using pair programming” (ibid).

Some educators have concerns about pair programming allowing one student in the pair to not do the work—thus getting credit without learning the materials. However, research has found that “students’ individual performance on final exams is similar whether students are learning to program using pair programming or using solo programming… [strongly refuting] any concern about significantly larger numbers of students sliding by without learning the material when working with a partner versus solo” (Simon, et al. 2019, p. 830).

How to Implement Pair Programming:

Pair programming is not throwing two students into a group and telling them to program. Students need to understand that pair programming is not a divide-and-conquer strategy—so to prevent this teachers can:

  1. Pair students with similar skill levels
  2. Provide materials covering what is pair programming:
    1. Suggestion for Higher Education: Williams, L. A., & Kessler, R. R. (2000). All I really need to know about pair programming I learned in kindergarten. Communications of the ACM, 43(5), 108-114.
    2. Suggestion for K12:
  3. Go over the expectations of each role
    1. Source: Campe, S., Green, E. & Denner, J. (2019). K-12 Pair Programming Toolkit. ETR, Scotts Valley, CA
       A Venn Diagram of Pair Programming
  4. Model what good driving and navigating looks like for the whole class
  5. Provide a clear workflow for troubleshooting common problems:
    1. Partner is unavailable
    2. Work feels inequitable
    3. Resolving disagreements
  6. Make sure you address the pair when providing help
    1. “When a student asks a question, make sure you address your answer to both of the students and take time to check that both students understand. If one student understands and the other student doesn’t, stay with the pair while one student explains it to the other one.” -
  7. Train your TAs to support pair programming—it’s a lot more about soft skills than they are used to!

Avoiding Pitfalls:

Pair programming is a complex, nuanced pedagogy. There are a few common pitfalls to avoid.

Pair programming is hard and students might resist all the extra work of using soft skills at first. This often leads to instructors trying pair programming once, and after pushback from students, reverting to individual assignments. This pushback is normal and expected! “[M]ost programmers are long conditioned to performing solitary work and often resist the transition to pair programming. Ultimately, most triumphantly make this transition” (Williams & Kessler, 2000, p.109). Commit to pair programming for the entire semester—if you allow the class to revert back to solo programming, neither you nor your students will reach a skill level where the benefits become clear.

Do not assume that equal drive time or equal code lines mean equal contribution. “Because of the variance in how measures can quantify interactions, [teachers] must be careful to select equity measures that are appropriate to [their context]” (Deitrick, et al. 2016, p. 377).

Some instructors think they can’t implement pair programming because they don’t have face-to-face time to dedicate to pair programming activities. “Remote pair programming, also known as distributed pair programming, has been known to be comparable to co-located pair programming in regards to student performance, effective code quality and productivity” (Kuttal et al. 2019, p. 75). With Codio, you can seamlessly get the benefits of pair programming, even with a fully online course!

Pair programming in Codio:

As the instructor, you can easily toggle Pair Programming on for any given assignment. Codio will send both students into the same container when they work on the assignment and propagate any auto-grader results to all students within a group. Additionally, you can create a more co-located experience for remote students by “locking” the navigator’s view to the driver’s view by toggling on “Shared Focus”.

Pair Programming - Settings

Teachers often worry about odd numbers—you can have more than 2 students in a group. This is often called “mob programming”—it has the same principles of 1 driver but with multiple navigators.

While we often describe how you can treat Codio as a coding GoogleDocs, our pair programming features is not “anarchy” mode where multiple students can type at the same time. Pair programming in Codio only allows there to be one driver as a purposeful scaffolding and support for good pair programming habits. Students can seamlessly transfer who is the driver on-demand by toggling the "Driver" button—or simply by waiting 15 seconds before the next driver starts typing.

Pair Programming - Chat Feature

Additionally, students don’t need a video conferencing service to pair program remotely in Codio. Just clicking on the phone icon in the top-right allows students to seamlessly communicate synchronously using video or audio within Codio. There is a Chat for students with limited bandwidth.

Pair Programming - Starting a Call

Pair programming is now live in Codio and can be used within any course. Any users with an instructor account can bring pair programming to life for their students.

Create Free Instructor Account


Deitrick, E., Shapiro, R. B., & Gravel, B. (2016). How do we assess equity in programming pairs?. Singapore: International Society of the Learning Sciences.

Kuttal, S. K., Gerstner, K., & Bejarano, A. (2019, October). Remote Pair Programming in Online CS Education: Investigating through a Gender Lens. In 2019 IEEE Symposium on Visual Languages and Human-Centric Computing (VL/HCC) (pp. 75-85). IEEE.

Simon, B., Hundhausen, C., McDowell, C., Werner, L., Hu, H., & Kussmaul, C. (2019). Students as teachers and communicators. The Cambridge Handbook of Computing Education Research, 827-857.

Williams, L. A., & Kessler, R. R. (2000). All I really need to know about pair programming I learned in kindergarten. Communications of the ACM, 43(5), 108-114.


Elise Deitrick

Elise is Codio's VP of Product & Partnerships. She believes in making quality educational experiences available to everyone. With a BS in Computer Science and a PhD in STEM Education, she has spent the last several years teaching robotics, computer science and engineering. Elise now uses that experience and expertise to shape Codio's product and content.