Fall 2018

CS 42: Principles and Practice of Computer Science

TTh 9:35am–10:50am in SHAN 2460

About This Course

This course is about computation, broadly defined. It challenges you to build on the knowledge you already have, to be vulnerable and open to learning, to share responsibility for everyone’s learning, to celebrate your mistakes, and to be comfortable with the not-yet-known.

This is an accelerated introductory computer science course, designed for students with significant computer science and/or programming experience. We assume that you have taken (and done very well in) at least one introductory computer science or introductory programming course. We assume you are familiar with Object Oriented prog1ramming, likely in Java. You should be comfortable programming in at least one widely used programming language. This course moves fast and covers a lot of ground, but it is also a lot of fun, and we get to study some very awesome CS concepts. This course covers most of the material in both CS 5 and CS 60. After completing this course you will be eligible to take any course that has CS 60 as a prerequisite.

If you are unsure about your placement in this class, please speak with Prof. Ben ASAP. It is possible to switch to CS 5 Black (which meets at the same time on the same days), but the earlier you decide to switch, the better.

Course Aims and Objectives

Mission Statement

CS 42, Principles and Practice of Computer Science, provides you with a broad overview of computer science, at the same time providing sufficient depth in a number of key conceptual areas that are intended to serve both majors and non-majors well. These concepts include:

All these concepts are important in both computer science and engineering. Programming in a variety of languages is used as a vehicle to demonstrate concepts. Language choice is not specifically made to match the often-changing demands of industry. Instead, we hope that each student gains experience in as wide a range of programming practices as possible. Underneath each assignment’s language are conceptual points that are language-independent.

The overarching goal is that, at the end of CS42, you’ll feel comfortable programming in any language—even one you’ve never seen before! That is, you will be a savvy computational thinker, not dependent on any particular technology.

Support and Communication

Graders / Tutors (aka “Grutors”)

There are several grutors for this course whose mission in life (at least some of the time) is to help convey the wonder of CS 42! They will be holding regular hours in the LAC lab and/or the Beckman CS labs in B102 and B105. They will also be grading your assignments.

Communication

Almost all class-related communication will happen on Piazza. Piazza is highly catered to getting you help fast and efficiently from classmates, the grutors, and the instructors. Rather than emailing questions directly to one person, you’ll post your questions on Piazza. Even if the question is something you think “only a professor can answer”, you should ask it on Piazza, where you can do so privately (i.e., so that only the professors and grutors can see it) or anonymously (i.e., without attaching your name). The only time you should not post to Piazza is if the matter has some kind of confidentiality requirement that means it would be inappropriate for grutors to see it. In that case, please send me (Ben) an email or talk to me in private.

Regardless of how you communicate—on Piazza or over email—you should receive a response within 24 hours. If you don’t, send me an(other) email to let me know.

Support

There are lots of ways to get support and help in CS 42, including:

In general, you should start by posting to Piazza, then by coming to tutoring or office hours. If there’s an issue that requires extensive help, you may want to head directly to an in-person meeting.

Feedback

Feedback is an important part of any learning. During this course I will be asking you to give me feedback on your learning in implicit ways (e.g., exams and assignments) as well as explicit ways (e.g., “How’s the class going for you?”). This is your class, and I want to make sure you get the most out of it. Please let me know right away when something we discuss is not clear. If you don’t understand something, chances are that several other students feel the same way. You are always free to interrupt me—don’t let me get away with glossing over any topic. I also welcome any feedback about the structure, tone, and nature of this course. I ask that you give me this kind of feedback outside of class — either in office hours or via email. If you would like to give me anonymous feedback, you can send anonymous email.

What You’ll Need

Accounts

Piazza
Most of our out-of-class communication happens here.
Gradescope
This system is how you’ll submit your assignments. When the time comes, we’ll give you information on how to log in.

Software

Most of the software we need is already installed on the College’s and CS department’s lab computers. If you want to use your own computer, you may need to install additional software. All the software is free, and we’ll provide information on how to install it when the time comes.

Books

There is no required textbook for this class. We try to provide everything you need to know in lectures or via other resources (e.g., handouts, web resources, information that comes with assignments, etc.).

However, you might find the following textbooks useful:

Classes, Coursework, and Grading

Attendance

On-time attendance at lectures is required in order to pass this course. If you are ill and cannot attend or an emergency arises, please let me know as soon as you can.

Grading

This course is considered a first-year course, and is graded on a Pass/No Pass scale. There are three graded components of this course, weighted as follows:

Assignments (~60% of total grade)
There will be an assignment every week (with exceptions for breaks). Unless stated otherwise, homework is due each Tuesday at 11:59 PM. We use an automated procedure to determine submission time, so if you submit even slightly after midnight, it will be recorded as being submitted the next day. We will use guidelines in grading the programming assignments which will be approximately as follows:
  • 75% of the points will be given for a program that meets the exact specifications of the assignment.
  • 25% of the points will be given for good design, style, testing and robustness. Good design and style means, for example, that your program is divided into small logical functions, new classes are defined and used when appropriate, and the program uses efficient algorithms and data structures. Your program should also be robust in the sense that it handles minor aberrations in user input, though extensive input error-checking is not required unless so specified. Finally, the code must be readable and well-documented.

We will try to give you very clear feedback indicating what could be done to improve the program. If the feedback isn’t entirely clear to you, please talk to me (Prof. Ben) or post a private message to the instructors on Piazza.

Also, I will drop the lowest-percentage assignment score, and not use it as part of your grade calculation.

Tests (~30% of total grade)
In addition to weekly assignments, there will be two midterms and one final exam. The dates for these exams are posted on the course webpage.
Participation (~10% of total grade)
I expect that you will be excited to contribute your opinions and reasoning both in and out of class. I also expect that you will moderate your participation so that everyone gets to participate in somewhat even proportions. This expectation means that you’ll probably have to go outside your comfort zone: if you’re someone who likes to answer every question, you’ll need to sit back and let someone else chime in; if you’re someone that prefers not to speak up, you’ll need to contribute your voice more often than you might like. Participation is a naturally subjective quality, though it can be measured. I will measure your participation in part by assigning quick thinking/writing exercises during class, asking for feedback on assignments, and observing your interactions with classmates. Rest assured, I want you to succeed. If you are concerned about your level of participation or how I might perceive it, please talk about it with me.

Final grades are computed with this Racket code as our rough guideline (exact boundaries subject to change):

    (define (score p)
        (cond
            ((>= p 0.97) "High Pass")
            ((>= p 0.70) "Pass")
            (else "We hope not to have to use this option"))
            

Important grading notes:

Lateness policy for assignments

You have three late days or “CS 42 Euros” that you may use at your discretion — you don’t need to tell us in advance. A late day allows you to turn in an assignment 24 hours late with no penalty. You may not use two late days on the same assignment. Late homeworks will not be accepted once these late days have been used. In cases of illness or emergency, contact me to see about an extension.

Pair programming, Honor Code, and conduct

Pair programming

For most of the programming assignments you will be permitted to “pair program” on some problems if you wish. The rules and guidelines for pair programming are as follows:

Now that you know the rules, here are some pair programming guidelines to help you get the most out of your experience:

Honor Code

Whether you are programming individually or as a pair, there are a few important rules regarding cooperation. You are always welcome and encouraged to discuss approaches to solving homework problems with any classmate, the grutors, or Prof. Ben. You may not share any written or typed materials of any kind. In particular, you may not send or receive code that is related to this course by e-mail, on the web, from another person’s file or printout, or in any other form. This rule applies to two people working as a pair with the following exception: The code may be sent by e-mail from one member of the pair to the other after the code is submitted for grading. Moreover, the pair may print out a copy of their code to work on together.

In short: you should conduct yourself in accordance with the Harvey Mudd Honor Code. If you have any questions, ask Prof. Ben.

You may wonder if it is permitted to help a classmate (other than your partner if you are pair programming) debug a program and, in the process, look at their code. This is permitted, assuming that it is done with the intent of helping your classmate learn, and not with intent of gleaning code that might be used in your own program, or with the intent of simply giving away answers. Use your good judgement here. If you have any questions about what behavior is acceptable, it is your responsibility to come see me before you engage in this behavior. I am more than happy to answer any questions you may have.

Classroom Conduct

The goals of this course can only be accomplished in a setting of mutual respect. All are welcomed and encouraged (indeed, required!) to actively participate in class, regardless of gender, race, nationality, native language, sexual orientation, gender identity, political ideology, and personal academic history.

Your rights as a student

Social Engagement

The mission of Harvey Mudd College is to prepare leaders who understand the impact of their work on society. Our institution is a vibrant part of that society, and we might be affected by the violence in our world and the tumult of this political season. Social justice demonstrations are likely to occur at the Claremont Colleges this year, and we understand that some students may wish to take part in these activities. Therefore, we are willing to accommodate your reasonable participation in such events, so long as you coordinate with your instructor in advance, ideally at least 24 hours before the affected class meeting time or due date.

Title IX

Harvey Mudd College is committed to providing an environment free of all forms of discrimination and sexual harassment, including sexual assault, domestic violence, dating violence, and stalking. If you (or someone you know) has experienced or experiences any of these incidents, know that you are not alone.

Please be aware that many HMC employees, including all faculty members, are considered Responsible Employees who are required to relay any information or reports of sexual misconduct they receive to the Title IX Coordinator. This means that if you tell me about a situation involving sexual harassment, sexual assault, dating violence, domestic violence, or stalking, I must report the information to the Title IX Coordinator. Although I have to report the situation, you will still have options about how your case will be handled, including whether or not you wish to pursue a formal complaint. Our goal is to make sure you are aware of the range of options available to you and have access to the resources you need.

If you wish to speak to someone confidentially, you can contact any of the following on-campus resources, who are not required to report the incident to the Title IX Coordinator: (1) the EmPOWER Center (909.607.2689), the Monsour Counseling Center (909.621.8202), and the McAlister Chaplains (909.621.8685). Additional information about your options is also available at https://www.hmc.edu/tix.

Accommodations

My goal is to make my course accessible to all of you! To request academic accommodations, you’ll contact the relevant disabilities resources person from your institution. Please send me any questions! I’m happy to help!