Data Abstraction and Problem Solving with Java
Frank M. Carrano, Janet Prichard
This book is based on the classic "Walls and Mirrors" approach used in the best-selling Data Abstraction and Problem Solving with C++, and is now updated to the Java programming language. It uses the running theme of "Walls and Mirrors" to help make clear the challenging concepts of recursion (the mirrors) and data abstraction (the walls). Authors Carrano and Prichard cover key object-oriented concepts, including encapsulation, inheritance, and polymorphism. However, the focus of the book remains on data abstraction.
- Provides a firm foundation in data abstraction (the walls), emphasizing the distinction between specification and implementation as the foundation for the object-oriented approach. Pg.__
- Offers extensive coverage of recursion (the mirrors) and uses the technique throughout many examples and exercises. Pg.__
- Introduces analysis of algorithms and Big "O" notation. Pg.__
- Provides an appendix covering basic Java syntax for those who know a different language or who need a refresher. Pg.__
- Contains many pedagogical study aids such as margin notes, cautionary warnings about common errors, programming projects, specifications for all major ADTs in both English and pseudecode, and self-test exercises with answers. Pg.__
- A proven approach, adapted from the best selling Data Abstraction and Problem Solving with C++. Pg.__
(NOTE: Each chapter concludes with a Summary, Cautions, Self-Test Exercises, Exercises and Programming Problems.)
I. PROBLEM-SOLVING TECHNIQUES.
The Life Cycle of Software.
What Is a Good Solution.
Achieving a Modular Design.
General Design Guidelines.
A Summary of Key Issues in Programming.
Ease of Use.
2. Recursion: The Mirrors.
A Recursive Void Method: Writing a String Backward.
Organizing a Parade.
Mr. Spock's Dilemma (Choosing k out of n Things).
Searching an Array.
Finding the kth Smallest Item of an Array.
Recursion and Efficiency.
3. Data Abstraction: The Walls.
The ADT Sorted List.
Designing an ADT.
An Array-Based Implementation of the ADT List.
4. Linked Lists.
Reference-Based Linked Lists.
Programming with Linked Lists.
Deleting a Specified Node from a Linked List.
Inserting a Node into a Specified Position of a Linked List.
A Reference-Based Implementation of the ADT List.
Comparing Array-Based and Reference-Based Implementations.
Passing a Linked List to a Method.
Processing Linked Lists Recursively.
Variations of the Linked List.
Circular Linked Lists.
Dummy Head Nodes.
Doubly Linked Lists.
Application: Maintaining an Inventory.
5. Recursion as a Problem-Solving Technique.
Two Simple Languages.
The Relationship Between Recursion and Mathematical Induction.
The Cost of Towers of Hanoi.
II. PROBLEM SOLVING WITH ABSTRACT DATA TYPES.
Simple Applications of the ADT Stack.
Recognizing Strings in a Language.
Implementations of the ADT Stack.
A Reference-Based Implementation of the ADT Stack.
An Implementation That Uses the ADT List.
Application: Algebraic Expressions.
Converting Infix Expressions to Equivalent Postfix Expressions.
Application: A Search Problem.
A Recursive Solution.
The Relationship Between Stacks and Recursion.
Simple Applications of the ADT Queue.
Implementations of the ADT Queue.
An Array-Based Implementation.
An Implementation That Uses the ADT List.
A Summary of Position-Oriented ADTs.
8. Class Relationships.
Java Access Modifiers.
Is-a and Has-a Relationships.
Dynamic Binding and Abstract Classes.
Java Interfaces Revisited (Iterators).
The ADTs LIST and Sorted List Revisited.
Implementations of the ADT Sorted List That Use the ADT List.
The Advantages of an Object-Oriented Approach.
9. Algorithm Efficiency and Sorting.
Algorithm Growth Rates.
Order-of-Magnitude Analysis and Big O Notation.
Keeping Your Perspective.
The Efficiency of Searching Algorithms.
Sorting Algorithms and Their Efficiency.
A Comparison of Sorting Algorithms.
The ADT Binary Tree.
General Operations of the ADT Binary Tree.
Traversals of a Binary Tree.
Possible Representations of a Binary Tree.
A Reference-Based Implementation of the ADT Binary Tree.
Tree Traversals Using an Iterator.
The ADT Binary Search Tree.
A Reference-Based Implementation of the ADT Binary Search Tree.
The Efficiency of Binary Search Tree Operations.
Saving a Binary Search Tree in a File.
11. Tables and Priority Queues.
A Sorted Array-Based Implementation of the ADT Table.
A Binary Search Tree Implementation of the ADT Table.
The ADT Priority Queue: A Variation of the ADT Table.
A Heap Implementation of the ADT Priority Queue.
12. Advanced Implementation of Tables.
The Efficiency of Hashing.
What Constitutes a Good Hash Function?
Table Traversal: An Inefficient Operation Under Hashing.
Data with Multiple Organizations.
Graphs as ADTs.
Applications of Graphs.
Minimum Spanning Trees.
Some Difficult Problems.
14. External Methods.
Sorting Data in an External File.
Appendix A: Review of Java Fundamentals.
How to Access Members of an Object.
Identifiers and Keywords.
Primitive Data Types.
Assignments and Expressions.
Useful Java Classes.
Text Input and Output.
The switch Statement.
The for Statement.
The do Statement.
File Input and Output.
A Comparison to C++.
Appendix B: Unicode Character Codes (ASCII Subset)..
Appendix C: Java Resources.
Appendix D: Mathematical Induction.
Answers to Self-Test Exercises.
For more information about any of the supplements listed below, use our Rep. Locator to contact your Addison Wesley representative.
- Online Instructor's Manual with Solutions