CS 231-A&B: Data Structures and Algorithms

Title image Spring 2022

Course Information for Spring 2022

Lectures
Section A: M-W-F 9:00 - 9:50 am, Lovejoy 213
Section B: M-W-F 11:00 - 11:50 am, Lovejoy 205
 
Labs
Lab A: M 1:00 - 2:20 pm Davis 102
Lab B: M 2:30 - 3:50 pm Davis 102
Lab C: T 1:00 - 2:20 pm Davis 102
Lab D: T 2:30 - 3:50 pm Davis 102

Instructor Information

Lectures
Section A: Prof. Hannen Wolfe
Office: Davis 114
Email: hewolfe@colby.edu
Office hours: Monday 2-4pm, Tuesday 3-4pm, Thursday 12-3pm, and by appointment.

Section B: Prof. Allen Harper
Office: Davis 113
Email: aharper@colby.edu
Office hours: MWF 12-1pm, M&Tu 4-5pm, or by appointment

Labs
Sections A&B: Prof. Allen Harper
Office: Davis 113
Email: aharper@colby.edu
Office hours: MWF 12-1pm, M&Tu 4-5pm, or by appointment

Lab TA Section A: Laura Drepanos
Lab TA Section B: Baron Wang

Sections C&D: Prof. Max Bender
Office: Davis 115
Email: mbender@colby.edu
Office hours: Prof. Bender's Office Hours


Lab TA Section C: Ella McNally
Lab TA Section D: Garam Choi


Lab and Project Links

#LabsProjectsDue Dates
1Java and ArrayListsMonte-Carlo Simulation: Blackjack13/14 February 2022
22D ArraysCellular Automata Simulation: Game of Life20/21 February 2022
3Cell, Stack and Partial Board ClassComplete Board Class28 February or 1 March: (1-point) Graded Check-In: Demo Your Working Cell, Stack and Board Classes During Lab
4Continue Development of Sudoku SolverFinal Sudoku SolverMonday March 7
5Linked ListsAgent-based Simulation: Grouping Behaviors18 March 2022 (Friday before Spring Break)
6QueuesDecision-Making Simulation: Checkout LinesMonday, April 4
7Binary Search Trees and SetsAnalysis: Word FrequencesMonday, April 11
8Hash TablesAnalysis: Comparing Data StructuresMonday, April 18
9Priority Queues: HeapsAnalysis: Word TrendsMonday, April 25
10Graph Implementation and Dijkstra's AlgorithmStart on Game: Hunt the WumpusMonday, May 2 (Submit Graph and Vertex classes)
11Continue Working on Hunt the WumpusGame: Hunt the WumpusFriday, May 6 (Last day of classes)

Summary of project grading policies:

A. Project instructions specify what you need to do to get 26/30. You need to do extra (extensions) to get 30/30.

B. If you turn it in on time, you can get up to 30 points. If you turn it in 1-7 days late, you will not get any extension points, so do not bother doing any extensions. If you are still not done with it after it is a week late, turn it in any way for partial credit. Projects will not be accepted after 1 week late and will receive a zero.

C. Projects must be submitted with a report. Projects will not be graded without a report. If your project is incomplete or not fully functional please explain what work you completed in your report along with documentation of what doesn't work.

D. To get your extension graded: A working version has to be provided (the grader should not have to edit code). For medium and large extensions make a copy of the project before starting on the extensions. If command line arguments are used to turn on and off an extension include a usage statement. Extensions must be documented in the report to be graded.

E. Each student gets one free extension of 4 days (a freebie).

Project Guidelines

Much of what you learn in this course will come from implementing a core set of data structures and algorithms. Each week in lab you will implement a new data structure, then use that data structure as the basis for the week's project. Each project will involve either simulation or analysis, mostly related to social science topics. As with all core CS courses, the defined part of the project will constitute about 85% of it. You can choose to stop there, or you can extend the project in ways that are interesting to you for additional credit. Each project will have some suggested extensions, but you are always free to choose your own.

A project will always have a coding part and an associated report. Your code should be well-written, well-commented, and efficient. The report gives you a chance to do two things: explain your code/design to others, and explain the results of your project. These are two different skills, both of which are important for any computer scientist or software developer. The first requires you to explain an algorithm or data structure using natural language. This is necessary in order to communicate or explain ideas in a structured manner. The second requires you to examine the results of your code, analyze whether it is working, and explain either the behavior of your simulation or what you discovered in your analysis. Note that the second part also helps you to ensure your code is working properly.

All projects will be graded out of 30 points. The code and quality comments constitute 21 points, the report constitutes 5 points, and you can earn up to an additional 4 points with extensions. A 30/30 project requires perfect code, a clear and well-written report, and meaningful or significant extensions. Note that doing lots of extensions will not make up for a poor report, code with errors, or code without comments.

The faculty and TAs are available to help you, especially with projects. Please follow the 30-minute rule: if you have not made any progress after 30 minutes of honest effort, stop what you are doing and ask a question of a TA or faculty. The point of the projects is not to be frustrated, but to make progress.

Success in the projects results from starting early, attending lecture and lab, making use of the course resources, and asking questions when you get stuck. All projects, except the last one, will be due on Monday evening by midnight. Projects submitted after the specified deadline will be graded without considering extensions. Any project work must be submitted within a week of the deadline to receive any credit. Submit what you have and move on to the next project.


Online Resources

Online Book Library

The Safari online book collection has many textbooks on Java and data structures.

Algorithm Visualization:

Links to web sites comparing Python to Java:
Links to free online data structures textbooks:
Links to Java online documentation, tutorial, and sample code: Note: The Java tutorial and the JDK API documentation (the first two links below) can be downloaded to your computer so that you don't need web access to view them. They also load a little faster if you use a local copy.
Links to free online Java help:
Links to free Java development environments: