Skip to main content

CSC 151.01, Class 06: Pair programming

Overview

  • Preliminaries [8:30–8:45]
    • Notes and news
    • Upcoming work
    • Extra credit
    • Friday PSA
    • Questions
  • Quiz [8:45–9:00]
  • Lab [9:00–9:25]
  • Discussion of pair programming [9:25–9:50]
    • Basics of pair programming
    • Benefits of pair programming
    • Exercise
    • Forming a code of conduct

Preliminaries

News / Etc.

  • Thanks for keeping the room neat.
  • I apologize that I am still far behind. I hope to catch up this weekend.

Upcoming work

Extra credit (Academic/Artistic)

  • Rebecca Wingo: How to Harvest History. Friday Feb. 2, 4pm, Burling Library Lounge.
  • CS Table, Tuesday, Noon, PDR A: Unknown topic
  • CS Extra, 4:15 p.m. Thursday, Science 3821: The design of CSC 151
    • Drinks and snacks at 4:00 p.m. in the CS Commons
  • Movie Sunday at 4 at Strand “I Am Not a Negro”.

Extra credit (Peer)

  • Indoor Track and Field: Grinnell Invitational, Saturday, 9:30 a.m. In the field house (Indoor track). (30 minutes is enough)
  • Swimming vs. Nebraska and Iowa State, Saturday, 1pm.
  • Tennis, 10am, Sunday (Field House)
  • Posse Plus Retreat Recap, February 6 at 11am, JRC 101.
  • KDIC Wednesdays at 6pm.
  • Friday the 9th, Contra Club Dance in Younker Lounge 1st, 8pm

Extra credit (Misc)

Other good things

Friday PSA

  • You are awesome people.
  • I care about you.
  • So please take care about yourself.
  • Think about what is appropriate for you, in advance.
  • Moderation in consumption.
  • Clear, unambigous consent is absolutely necessary.

Questions

There hasn’t been enough time to do lab in class. Will that change?
I certainly hope so. My goal is that you can finish lab during class time.
Can you explain the difference between modulo and remainder?
It’s not relevant right now.
Did you have a nice dinner with the trustees?
Yes. Although I don’t always agree with them, we share a strong commitment to this institution.
Do you mind receiving email question?
No, not at all.

Quiz

  • Work on the quiz.
  • When you are done, put down your pencil or pen and meditate quietly.
  • When the buzzer beeps, please pass your quizzes to the east, where our mentors will gather them.

Lab Time

We’ll work on the procedures lab until 9:25 or so.

  • If you had finished the lab already, you may
    • (a) do the “For those with extra time”
    • (b) work on the homework assignment

Homework note: Neurobiology breaks the formatting policy. Change it to read -1 24 rather than -13 12.

"79911 BIO-363-01 4.00 -13 12 Neurobiology w/lab"
"79911 BIO-363-01 4.00 -1 24 Neurobiology w/lab"

Homework note. Over the longer term, you will be better off using the following format for procedure definitions that use lambda.

(define proc
  (lambda (param)
    body))

Basics of pair programming

Suppose the rest of the class had not done the reading. Explain.

  • Two people working on the computer
    • Driver: One doing the typing of othe code
    • Navigator: The other looking over their shoulder
  • The driver and navigator should be communication.
  • Which means the driver should be talking out loud about their though process.
  • The navigator can
    • Point out errors
    • Suggest other approaches (e.g., “This would be so much nicer if ..”)
    • Ask questions
    • Take a big-picture view
    • Serve as a reference

Benefits of pair programming

Suppose the rest of the class had not done the reading. Suggest benefits.

  • Better code.
  • Learn new ways to solve.
  • Talking out loud about problems in the code helps you find them.

Exercise

Our mentors have distributed cards with simulated quotations from past CSC 151 students. Please read your cards aloud.

Forming a code of conduct

Lab writeup: …

  • Something you’d like to see in the code of conduct.