Labs and Assignments
Brady, Pamela Cutter, Kelly Schultz
CS 2 / AP CS AB
Introductory Lab Series
Lab Series: series of labs that deal with constructing objects,
invoking methods, basic flow control constructs, and implementing classes.
Can be used to help bring students who learned to program in another language
up-to-speed in Java.
Data Structures Labs and Programming Assignments
Students implement iterators for a number of different traversals and partial-traversals
of a two-dimensional
BoundedEnv data structure.
- Linked Lists:
A program that uses an iterator through a circular linked list (Bad
News Bearers) followed by a set of exercises that explore
the implementation of linked lists.
- Queues: a lab
program (Car Wash) that uses the AP
- Recursion - NQueens:
Students implement a solution to the classic N Queens problem, using a recursive
backtracking algorithm and a
BoundedEnv object as the N x N board.
- Trees: Labs in which students implement
a number of methods that traverse a binary
tree and a binary search tree.
AP® Marine Biology Simulation Case Study:
VLBoundedEnv (see bullet 1 of Exercise
3 on p. 104 of the MBS
SparseMatrixEnv (see bullet 2 of Exercise 3 on p. 104 of the
HMUnboundedEnv (see Exercise 6 on p. 104 of the MBS
*AP and Advanced Placement are registered trademarks of the
College Entrance Examination Board, which has not endorsed this workshop or
Last modified on
by Alyce Brady.