This course couples work on program design, analysis, and verification with an introduction to the study of data structures that are important in the construction of sophisticated computer programs. Because we will be interested in studying more modern techniques for designing and implementing efficient computer programs, we will be using the object-oriented programming language, Java. We will see that the object-oriented style of programming is extremely useful in designing large, complex programs and supporting reusable software.
Students will be expected to write a collection of programs, ranging from very short programs to more elaborate systems. Since one of our goals in this course is to teach you how to write large, reliable programs composed from reusable pieces, we will be emphasizing the development of clear, modular programs that are easy to read, debug, verify, analyze, and modify.
Equally important is the ability to analyze programs for correctness and using big-"O" notation to understand their runtimes. This will help us evaluate the trade-offs in different choices of algorithms and data structures.
The formal pre-requisite for this course is Pomona CS 52. We also assume that all students enrolled are comfortable writing small to medium-sized programs (around 500 lines of code with several interacting classes) in Java. The knowledge assumed is generally equivalent to that of CSCI 051 as offered at either Pomona or CMC or the Computer Science advanced placement exam. Be aware that neither CS 5 at HMC or CS 30 at Pomona satisfy the prerequisites for this course. In particular, neither teaches the Java skills required for this course. If you have any doubts as to whether your programming experience is sufficient for this course, please see us as soon as possible.
If you have never programmed in Java, check with the instructors for proper placement. As part of likely forthcoming curricular changes in CS, the sections of CS 62 taught in Fall 2018 and beyond will likely not require the knowledge of Java, and Java will be taught in the course. However, all sections taught during the 2017-18 academic year will continue to depend on the knowledge of Java.
By the end of this course, you should have a good understanding of object-oriented design, coding and debugging of programs in Java, and have a good understanding of how one might analyze programs for correctness and efficiency. In particular, you will understand the trade-offs involved in selections of different data structures and algorithms to solve computational problems.
This course is a prerequisite for most upper level Computer Science courses. As part of continuing curricular changes in CS, sections of CS 62 will no longer teach C or C++. Instead that material will be taught in CS 105 taught at Pomona. Students should be aware, however, that sections of CS 105 taught at HMC will assume programming background in C. Thus students wishing to take that course at HMC will be required to learn C on their own.
If you are seeking academic accommodations, you must contact your home college’s disability coordinator to establish accommodations. You should plan to meet with your coordinator to discuss appropriate accommodations and may be asked to provide documentation necessary to verify disabilities. Further information is available from the Student Disability Resource Center at CUC.
Use of electronics in the classroom
Laptops, tablets, and cell phones may not be used during lecture without advance permission of the instructor. Several studies (and our personal experience) has shown that these devices are a distraction and interfere with learning. Other studies have shown that taking notes by hand is more effective for learning than taking notes on a computer. We strongly recommend that you print out the lecture notes before class (they should be posted by 8:30 a.m. each class day) and annotate them by hand.
Pomona College prohibits video or voice recording of any lecture or discussion, except in cases that the office of the Dean of Students has granted a student permission according to the College’s Disability Accommodations Policy, or when permission is granted by the instructor. Please see one of the instructors if you wish to record lectures or lab sessions.
|Lectures:||MWF 10:00 - 10:50 am, Edmunds 101|
|TAs:||David Ahia, Alia Buckner, Arianna Chen, Emily Chen, Sam Gearou, Matthew Paik, Levente Papp, Sarp Misoglu|
|TA hours:||Th 8-10 pm, Sa 1-3pm, Su 1-3 pm, 8-11pm. Thursday's mentor session will also focus on problems from the text.|
|Labs:||W 1:15 - 2:30 pm, W 2:45 - 4:00 pm, in Edmunds 229|
Duane Bailey, Java Structures, sqrt(7) edition, 2007.
The book is available for free online.
Students should consult this page regularly to see the most current version of the schedule of topics and readings.
All reading assignments are from the text. Students should come to class having completed the indicated readings for the day. You should attempt to work all the problems at the end of each section as you are reading. Chapter review problems will be assigned during each lecture. While chapter review problems will not be turned in, you should complete them before the next lecture after they are assigned. Many of these will show up in the regular quizzes during the first five minutes on Friday mornings, and may also appear on the midterm or final. Problems assigned in association with lecture n should be completed before lecture n+1. Answers are in the back of the book for most problems assigned.
|1)||Jan 17||Introduction & Overview||Ch 0 & 1, Appendix B.3.2||1.1|
|2)||Jan 19||Java & Javadoc||code||Appendix B.3.2||1.3|
|3)||Jan 22||Java Graphics & Events||code||Swing and Graphics Handouts|
|4)||Jan 24||Lists and listeners||Ch 3 & 4||3.7|
|5)||Jan 26||Listeners and Assertions||code||Ch 2, Using Assertions||2.1,2.3|
|6)||Jan 29||ArrayList Implementation||code||Ch 3 & 4||3.5, 3.7|
|7)||Jan 31||Analysis of Algorithms||Ch 5.1||5.5, 5.9, 5.11|
|8)||Feb 2||Induction/Sorting||Ch 5.2-3, Ch 6||5.21,5.23|
|9)||Feb 5||More Sorting||code||Ch 6||6.7|
|10)||Feb 7||Iterators||code||Ch 8||8.3|
|11)||Feb 9||Singly Linked Lists||Ch 9||9.5|
|12)||Feb 12||Doubly Linked Lists||Ch 9||9.15|
|13)||Feb 14||Stacks||Ch 10.1||10.3|
|14)||Feb 16||Stacks & Queues||Ch 10.1||10.3|
|15)||Feb 19||Queues & Practice Problems||code||Ch 10.2, 11||10.5|
|16)||Feb 21||Binary Trees I||Ch 12.1-5||12.3, 12.7|
|17)||Feb 23||Binary Trees II||Ch 12.6-12.10||12.11|
|18)||Feb 26||Review for Midterm 1|
|19)||Feb 28||Playing on Trees: Iterators (midterm in lab)||code||Ch 12.6-12.10||12.11|
|20)||Mar 2||Array Representations of Trees & Heaps||Ch 13.1-13.4.1||13.1, 13.2|
|21)||Mar 5||Priority Queues & Heapsort||Ch 13.4.2-13.6|
|22)||Mar 7||Ordered Structures||code||Ch 11|
|23)||Mar 9||Binary Search Trees||Ch 14.1-8||14.3,14.5,14.11|
|Mar 12-16||Spring Recess|
|24)||Mar 19||Balanced Binary Search Trees|
|25)||Mar 21||Maps & Dictionaries||Ch 15.1-3|
|26)||Mar 23||More Dictionaries & Hashing||Ch 15.4-7||15.3, 15.9|
|27)||Mar 26||Parallelism I||Handout, sec. 2, 3|
|28)||Mar 28||Parallelism II||code||Handout, sec. 4, 5|
|Mar 30||César Chávez Day|
|29)||Apr 2||Review for midterm II|
|30)||Apr 4||Data Ethics (midterm in lab)|
|31)||Apr 6||Parallelism II and Concurrency I||Handout, sec. 6|
|32)||Apr 9||Concurrency II||code||Handout, sec. 7|
|33)||Apr 11||Concurrency III||Handout, sec. 8, 9, Sample Probs|
|34)||Apr 13||Concurrency IV||Handout, sec. 8, 9, Sample Probs|
|35)||Apr 16||Concurrency and Graphs I||Ch 16||16.1, 16.3|
|36)||Apr 18||Graphs II||Ch 16||16.7|
|37)||Apr 20||Graphs III||Ch 16|
|38)||Apr 23||Graphs IV||Ch 16|
|40)||Apr 27||Practice Time|
|41)||Apr 30||Design Patterns|
Assignments & Labs
Labs for this course will be held on Wednesday afternoons from 1:15 p.m to 2:30 p.m. and from 2:45 p.m. to 4 p.m. in
229 Edmunds. The room is equipped with iMac computers.
Attendance at these lab sessions is mandatory. Please arrive well prepared for the lab, having read the description thoroughly.
Unlike in CS 51 at Pomona, lab work will generally be distinct from the weekly programming assignments, though the lab work will generally be relevant to those longer assignments. Instead, we will often use lab time to introduce you to new software tools and techniques that require more hands-on experience to understand. You will usually need to submit your results from the lab by end of the lab period.
There will be two types of weekly programming assignments: individual programs and team programs. All programs assigned
during the semester should be completed following the guidelines in the Academic Honesty Policy.
There will be 10 to 12 weekly programs due. All programs will be graded on design, documentation and style, correctness, and efficiency. The elements of a good program are very much like the elements of a good paper. It must be correct, but it should also be written in a style that is clear and elegant. Most programs will be tested using automated tools, so it is essential that your program meet all of the specifications provided in the assignment handout. You will also receive written comments on all of your programs
Weekly assignments will generally be due on Sunday evenings at 11:59 p.m. There will be a penalty assessed of 3n % for a program that is n days late. Programs will not be accepted more than four days late. It is usually better
to turn in a correct and well-documented program one or two days late than a non-functioning or non-documented program
All assignments should be submitted electronically. The procedure will be explained in the laboratory.
|Jan 24||Eclipse & Silver Dollar||Graphic Silver Dollar Game|
|Jan 31||Timing||Text Generator|
|Feb 7||Analysis of Algorithms||On-Disk Sort|
|Feb 21||Eclipse Debugger||Calculator|
|Feb 28||No Lab - Midterm 1!||Darwin, cont.|
|Mar 7||Git||Darwin, cont.|
|Mar 14||No Lab - Spring Recess!||No Assignment!|
|Mar 21||Binary Trees||Hex-A-Pawn|
|Mar 28||Binary Search Trees||Autocomplete|
|Apr 4||No Lab - Midterm 2!||Census Data|
|Apr 11||Parallelism||Census Data, cont.|
|Apr 25||Graph Algorithms||Driving Directions|
|May 2||No Lab!||No Assignment!|
Documentation & Handouts
The following documents provide information on the standard Java libraries and the additional libraries we have developed for this course:
- Submission Instructions
- CS 62 Style Guide
- Bailey materials
- Java materials
- Java Tutorial from Oracle
- Java 9 Libraries
- Programming with Assertions
- Moti Ben-Ari's Guide to Compile and Runtime errors in Java
- Iterating over collections in Java 8
- Java Graphics
- JUnit materials
There will be two in-class midterm exams plus a scheduled final exam. There will also be quizzes every Friday except the first week of classes. The quizzes will be during the first five minutes of class. No make-ups will be allowed, but the two lowest scores will be dropped to make up for illness or other absences.
- Midterm examination 1: Wednesday, February 28, in lab.
- Midterm examination 2: Wednesday, April 4, in lab.
- Final examination: Tuesday, May 8th, in class.
The midterms will be given during your lab period in order to allow 75 minutes to work on the exam rather than the 50 minutes available during a class period. We will place sample midterm exams on-line approximately a week before each exam.
|Weekly Programming Assignments||35%|
Collaboration & Academic Honesty
The Computer Science Department seeks to create a friendly and supportive learning environment. We encourage students to work in groups to review material from the lectures and readings, to work practice problems from the text, to study for exams, and to discuss the general ideas and approaches to assignments. However, work submitted for a course must be done independently, unless collaboration on a particular assignment is explicitly permitted. Effective learning is compromised when this principle is violated. As explained in the Pomona College Student Handbook, this means that the work you turn in must represent only your own work. It must not be based on help from others or information obtained from sources other than those approved by the instructors.
The following discussion reflects our general understanding of academic honesty in the Computer Science Department. Any exceptions or differences will appear in the course syllabus or the instructions for an assignment. Ask your instructor if you are ever unsure about what constitutes acceptable behavior.
The types of work and the level of expected collaboration vary from course to course and assignment to assignment. In this section, we describe some typical expectations. Instructors will often indicate that an assignment falls into a particular category, occasionally with additional remarks about the use of specific materials or sources. Students may freely use any resource that is provided by the instructor for an assignment.
Most work in our courses is to be completed individually. In general, the work that is submitted for an assignment must be the student's own. Students may not submit work under their own name that is done by, or in collaboration with, someone else. Copying solutions from any source, including the web or students in previous offerings of the course, is not allowed.
Students should not read or possess copies in any form--physical or electronic--of another student's work. There is no legitimate reason for a student to possess a copy of another student's assignment, to send a copy of student work from one computer account to another, or to be logged-on to another student's account. Providing one's own work to another student is also a violation of these policies.
We routinely use software and other tools to detect similarities between submissions. Identical, or nearly identical, submissions will be considered conclusive evidence of plagiarism.
For programming assignments, students may normally discuss general approaches to assignments, and they may give or receive "consulting" help for specific problems with software or computer programs. A student may look at another student's work only when help is requested. In that situation, the student takes on the role of mentor, and the interaction must be limited to the immediate problem. Two students sitting side-by-side and working through a program step-by-step will certainly produce work that will be considered evidence of illegal collaboration.
On problem sets, group discussion of the general ideas and approaches is permitted, provided the group members are noted on the submitted solutions. However, each student must write the solutions apart from the group, without consulting notes or other artifacts from the discussion. Although papers are less common in computer science classes, when they are assigned they must adhere to the usual levels of academic integrity. The prose must be the student's own, and all external sources must be properly cited.
Sometimes assignments are to be done by small teams of students. In these situations, the team takes on the role of an individual in the preceding discussion. The members of a team may communicate with one another, but collaboration with members of a different team is not permitted.
Exams and test programs
As stated in the Pomona College Student Handbook, "Students neither give nor receive assistance with examinations." Each examination will have a clear statement of what resources are permitted. Any use of material beyond those limits is not allowed. Take-home examinations will have time limits and similarly explicit rules; they are subject to the same policies. During examinations students may ask the instructor questions of clarification. The instructor will decide how complete an answer can be given. Some courses have "test programs" which are programming assignments that are to be treated in the same way as take-home examinations.
Some assignments are intended to give students comfort with a programming language feature or software environment. On these, any kind of assistance is permitted. The point is to get the work done.
Use of course materials
Course materials that are distributed in class, on Sakai, on the web, or by other means are provided solely for students in the class. Students are encouraged to use them to the fullest extent, but they are not to publish or distribute them to other people or organizations.
Responsibility of mentors and graders
Course assistants are routinely provided with solution sets to assignments. The solutions are intended to be an aid to effective mentoring and grading. Course assistants are not to distribute the solutions, in whole or in part, at any time. Graders who encounter suspicious similarities between submissions must report those instances to the instructor in the course.
Failure to abide by our rules will be considered a violation of the college's academic honesty policy and will result in severe penalties. Instances of plagiarism are easy to identify and will be handled promptly. The first offense typically results in failure in the course and is always reported to the Dean of Students Office. A second offense is automatically referred to the College's Board of Academic Discipline. See the Academic Honesty Policy in the Pomona College Student Handbook for further information. Students from other Claremont Colleges will be treated according to the procedures of their home campus. Please do not put us, yourself, or anyone else in an unpleasant situation.
In this class, the default penalty for any sort of academic dishonesty shall be failure in the course. Please do not put yourself or any of your classmates in this position.