CS106B: Programming Abstractions

Spring 2018
Monday/Wednesday/Friday 2:30pm to 3:20pm in NVIDIA Auditorium


Course Overview
icon Piazza
Lecture Videos
icon QT Creator
icon Stanford C++ Lib
Blank Project



Thur. May 3rd

Friday, June 8th


Lecturer: Chris Gregg
Gates 191
Tue 4:45-6:15pm
Wed 4:45-6:15pm

Head TA Nick Troccoli
Gates B02
Mon 10AM-12PM


Sunday 7-9PM
Tues 8-10PM
Wed 6-7:30PM
Wed 7:30-9PM (4/18)

Sign up here (free QueueStatus account required).

Tell us how we're doing with SCPD Office Hours! Fill out this survey.

For SCPD students only. All office hours in PST.


Important Announcements

We have several important announcements following today's lecture:

  1. Assignment Due Times 6PM: We have decided to change all assignment due times beginning with HW3 to be at 6PM PST instead of 12PM PST. This also means that, beginning with HW3, 1 late day is until the next class day at 6PM PST instead of 12PM PST.
  2. Midterm Scheduling: The midterm is coming up next Thursday 4/3 6-8PM. If you have significant academic or other conflict and cannot make this time, please fill out this form by Friday 4/27 and we will schedule an alternate time for you to take the exam. Additionally, if you have OAE accommodations, please email Chris and Nick with your OAE information as soon as possible so that we can schedule your accommodations.
  3. Midterm On Laptops: The midterm exam will be administered on computers using BlueBook software. If you do not have access to a laptop, or do have access but do not feel comfortable taking the exam on that laptop, please let Chris and Nick know as soon as possible.
  4. Reminder - Double-check HW Submissions: As a reminder, it is your responsibility to check that your homework submission is correct, and contains the required files for each assignment. In particular, you should not be submitting your entire project, or your .pro file. After submitting, please visit Paperless to view your submission and make sure the correct files were sent. We cannot allow resubmissions due to incorrect files being submitted.
  5. Pair Programming: when submitting as a pair, one person must submit and input their partner's SUNET ID. That partner then must confirm the pair submission request in their account on Paperless. We cannot grade your pair submission until you approve this pair request.
  6. Style Guide Updated: we have updated the style guide (under the "Tools" tab) with some notes on using recursion in your programs. Take a look!

Third Assignment: Recursion

For your third assignment, you'll get practice writing programs using recursion. This assignment consists of two programs - "Fractals", which draws recursive graphical patterns, and "Grammar Solver", which can generate random writing in the style of a specified structure.

We'll be holding the YEAH (Your Early Assignment Help) hours session later today (4/19) from 4:30PM-5:20PM in Skilling Auditorium (recording and slides available after). YEAH hours are sessions meant to help you get started on each assignment and answer questions, give you tips and tricks, and more. We hope to see you there!
Update: the materials have been posted on the assignment 3 page. Thanks to everyone who came!

Python to C++ Materials

Thanks to everyone who came to our Python to C++ session! The video has been posted to the lecture videos page, and the slides are available under the "Handouts" dropdown.

Second Assignment: Serafini

For your second assignment, you'll get practice writing programs using ADTs. This assignment consists of two programs - "Word Ladder", which generates connections between two different English words, and "Random Writer", which can generate random writing in the style of another writer.

Section/Grader Assignments

For those who submitted section preferences by 5PM on Sunday, section assignments are available starting at 5PM from the link in the Sections dropdown. SCPD students can view their graders at that link as well. If you were unable to submit the form by the 5PM Sunday deadline, the late signup form is available starting at 5PM under the "Sections" tab. As a reminder, SCPD students should sign up via the special SCPD link there instead.

If you would like to switch to a different section, you can swap by using the link in the "Sections" dropdown in the Sections dropdown. If you would like to switch into a different section to be with a requested partner, but you or your partner's sections are not available to swap into, please request a swap by filling out this form. For this form, please be sure to fill out ALL possible times you and your partner are free, not just your current section times.

The deadline for signups and swaps is Wednesday, 4/18, at 12PM. As a reminder, sections start this week!

Course Logistics Updates

We have a few important logistical notes as we enter the start of week 2:

  1. We are accepting submissions for HWs on cs198.stanford.edu/paperless. There, you can log in and drag-and-drop assingment files. Please see the specific assignment instructions for which files to submit.
  2. Sections will be finalized by tomorrow at 5PM; after that time, you may go to cs198.stanford.edu to view your assigned section. As a reminder, sections start this week! If you did not sign up for a section (or a grader, for SCPD), the late signup form will be open starting tomorrow at 5PM on cs198.stanford.edu.
  3. For the Game of Life assignment, we have updated the assignment webpage to indicate that, when prompting the user for wrapping, you should reprompt the user if they enter something other than y or n. Using the built-in getYesOrNo is acceptable.
  4. We have updated the general information handout to clarify course policies on late days (each student has 2, and they are class days), as well as policies surrounding pair programming (which will optionally be available for some future assignments).
  5. Nick has finalized his office hours schedule, and will be both in the LaIR as well as hold office hours in Gates B02 on Mondays from 10AM-12PM PST.
  6. We have added due dates for all assignments for the remainder of the quarter to the schedule page (right-most link in the navigation bar).
  7. As a helpful note, you can find the "rotateGrid" project that Chris mentioned last week (written in C++, Java, Javascript and Python) at this link.

Assignment 1 Released!

Assignment 1 has been posted. The YEAH video describing the assignment can be found on Canvas under "Beta Lecture Videos->YEAH Videos".

QT Creator Troubleshooting Session

If you have trouble setting up QT Creator, please feel free to come by our QT Creator troubleshooting session, happening on Wednesday, April 4 7-9PM in the LaIR (Tresidder first floor eating area).


Welcome to CS106B! We are looking forward to a fun quarter. Class starts Monday April 2nd at 2:30pm in NVIDIA Auditorium.

Sign Up for Piazza

This quarter CS106B is using Piazza to facilitate questions. Go to https://piazza.com/stanford/spring2018/cs106b/ to sign up. You can ask course related questions and see answers to other student questions. For personal questions please feel free to email Nick or Chris.

How to Create a Blank Project Video

See below for a short instructional video on how to create a blank project from a copy of another project.