There are a number of special features that I believe together make this book a unique approach to covering the subject of data structures and algorithms:
Consistent format for every chapter
Every chapter (excluding those in the first part of the book) follows a consistent format. This format allows most of the book to be read as a textbook or a reference, whichever is needed at the moment.
Clearly identified topics and applications
Each chapter (except ) begins with a brief introduction, followed by a list of clearly identified topics and their relevance to real applications.
Analyses of every operation, algorithm, and example
An analysis is provided for every operation of abstract datatypes, every algorithm in the algorithms chapters, and every example throughout the book. Each analysis uses the techniques presented in .
Real examples, not just trivial exercises
All examples are from real applications, not just trivial exercises. Examples like these are exciting and teach more than just the topic being demonstrated.
Real implementations using real code
All implementations are written in C, not pseudocode. The benefit of this is that when implementing many data structures and algorithms, there are considerable details pseudocode does not address.
Questions and answers for further thought
At the end of each chapter (except ), there is a series of questions along with their answers. These emphasize important ideas from the chapter and touch on additional topics.
Lists of related topics for further exploration
At the end of each chapter (except ), there is a list of related topics for further exploration. Each topic is presented with a brief description.
Numerous cross references and call-outs
Cross references and call-outs mark topics mentioned in one place that are introduced elsewhere. Thus, it is easy to locate additional information.
Insightful organization and application of topics
Many of the data structures or algorithms in one chapter use data structures and algorithms presented elsewhere in the book. Thus, they serve as examples of how to use other data structures and algorithms themselves. All dependencies are carefully marked with a cross reference or call-out.
Coverage of fundamental topics, plus more
This book covers the fundamental data structures and algorithms of computer science. It also covers several topics not normally addressed in books on the subject. These include numerical methods, data compression (in more detail), data encryption, and geometric algorithms.
About the Code
All implementations in this book are in C. C was chosen because it is still the most general-purpose language in use today. It is also one of the best languages in which to explore the details of data structures and algorithms while still working at a fairly high level. It may be helpful to note a few things about the code in this book.
All code focuses on pedagogy first
There is also a focus on efficiency, but the primary purpose of all code is to teach the topic it addresses in a clear manner.
All code has been fully tested on four platforms
The platforms used for testing were HP-UX 10.20, SunOs 5.6, Red Hat Linux 5.1, and DOS/Windows NT/95/98. See the readme file on the accompanying website http://examples.oreilly.com/masteralgoc/) for additional information.
Headers document all public interfaces
Every implementation includes a header that documents the public interface. Most headers are shown in this book. However, headers that contain only prototypes are not. (For instance, includes sort.h , but this header is not shown because it contains only prototypes to various sorting functions.)
Static functions are used for private functions
Static functions have file scope, so this fact is used to keep private functions private. Functions specific to a data structure or algorithm's implementation are thus kept out of its public interface.
Naming conventions are applied throughout the code
Defined constants appear entirely in uppercase. Datatypes and global variables begin with an uppercase character. Local variables begin with a lowercase character. Operations of abstract datatypes begin with the name of the type in lowercase, followed by an underscore, then the name of the operation in lowercase.
All code contains numerous comments
All comments are designed to let developers follow the logic of the code without reading much of the code itself. This is useful when trying to make connections between the code and explanations in the text.