Study Guide for Second Midterm
Spring 2002, David Matuszek

Binary trees:

Learn the terminology (root, left and right children, depth, size, leaf, balanced, etc.) Learn and understand the six recursive traversals.

Binary tree ADT:

This was basically an example, and can pretty much be ignored. However, you should understand what serialization is all about, and what getters and setters are (and why we use them).

ADTs:

Review the first set of slides, so that you can define an ADT, and you know what contracts are all about. Learn the terminology: constructor, accessor, applicative and mutative transformers, necessary and sufficient (and convenient) operations. Understand why immutable objects are sometimes better.

Stacks, queues, and deques:

Understand the various implementations.

Java I/O:

Don't memorize code. But do remember the open-use-close sequence, memorize the conditions for serializability, and understand the differences between serialization and using a text file. Oh, and understand what "flushing the buffer" is all about.

Comparisons:

There's a lot here. Again, don't memorize code; but learn the difference between Comparable and Comparator, and why you would want to use each. Understand the connections between hashCode and equals.

Using static variables:

Review briefly. Not much here, really.

The Java Collections framework:

Review the First Glimpse, Lists, Sets and Maps, and Using Maps. Better yet, read Sun's Collections Trail (just the Introduction, the several pages on Interfaces, and the one page on General Purpose Implementations; the rest is also very useful but won't be covered on this exam). Learn the hierarchy, and have a good idea what operations apply to all collections. Java's Collections framework will be emphasized pretty heavily on the midterm.

Threads:

This material will not be on the second midterm.

The Pragmatic Programmer:

Read chapters 3, 4, and 5.