for a handy companion book in a curriculum that allows for either a Java or C++
track in the introductory courses.
• M.T. Goodrich and R. Tamassia, Algorithm Design: Foundations, Analysis, and
Internet Examples, John Wiley & Sons, Inc., 2002. This is a textbook for a more
advanced algorithms and data structures course, such as CS210 (T/W/C/S versions)
in the IEEE/ACM 2001 curriculum.
Use as a Textbook
The design and analysis of efficient data structures has long been recognized as a
vital subject in computing, for the study of data structures is part of the core of
every collegiate computer science and computer engineering major program we are
familiar with. Typically, the introductory courses are presented as a two- or three-
course sequence. Elementary data structures are often briefly introduced in the first
programming or introduction to computer science course and this is followed by a
more in-depth introduction to data structures in the following course(s).
Furthermore, this course sequence is typically followed at a later point in the
curriculum by a more in-depth study of data structures and algorithms. We feel that
the central role of data structure design and analysis in the curriculum is fully
justified, given the importance of efficient data structures in most software systems,
including the Web, operating systems, databases, compilers, and scientific
simulation systems.
With the emergence of the object-oriented paradigm as the framework of choice for
building robust and reusable software, we have tried to take a consistent
objectoriented viewpoint throughout this text. One of the main ideas of the object-
oriented approach is that data should be presented as being encapsulated with the
methods that access and modify them. That is, rather than simply viewing data as a
collection of bytes and addresses, we think of data as instances of an abstract data
type (ADT) that include a repertory of methods for performing operations on the
data. Likewise, object-oriented solutions are often organized utilizing common
design patterns, which facilitate software reuse and robustness. Thus, we present
each data structure using ADTs and their respective implementations and we
introduce important design patterns as means to organize those implementations
into classes, methods, and objects.
For each ADT presented in this book, we provide an associated Java interface.
Also, concrete data structures realizing the ADTs are provided as Java classes
implementing the interfaces above. We also give Java implementations of
fundamental algorithms (such as sorting and graph traversals) and of sample
applications of data structures (such as HTML tag matching and a photo album).
Due to space limitations, we sometimes show only code fragments in the book and
make additional source code available on the companion Web site,
http://java.datastructures.net.
4