
Secure Data Structures and Algorithms with C++: Walls and Mirrors, 8th edition
- Frank M. Carrano
- , Timothy M. Henry
Learn more, spend less
- Find it fast
Quickly navigate your eTextbook with search
- Stay organized
Access all your eTextbooks in one place
- Easily continue access
Keep learning with auto-renew
Whether you’re interested in designing video games or software for robotic-controlled surgery, the study of data structures is vital. Secure Data Structures & Algorithms with C++ takes a unique walls and mirrors approach, presenting problem-solving techniques related to data abstraction (walls) and the efficient access and manipulation of data via recursion (mirrors). It emphasizes core data structures and object-oriented programming techniques for a strong foundation in data abstraction.
In the 8th Edition, C++ code now uses exceptions and C++20 features, such as smart pointers, while following safe and secure coding techniques aligning with SEI CERT Coding Standards. Material is reorganized, with chapters divided into 4 sections; new and refined examples and figures appear throughout; and much more.
Published by Pearson (July 2nd 2024) - Copyright © 2025
ISBN-13: 9780138122805
Subject: Programming - Intermediate/Advanced
Category: C++ Data Structures
The Foundation
- 1. Data Abstraction: The Walls
- 1.1 Object-Oriented Problem Solving
- 1.2 Achieving a Better Solution
- 1.3 Specifying the Solution
- 1.4 Abstract Data Types
- C++ Interlude 1: C++ Classes
- 2. Bags
- 2.1 The ADT Bag
- 2.2 The ADT NoDuplicatesBag
- 3. Array-Based Implementations
- 3.1 The Approach
- 3.2 An Array-Based Implementation of the ADT Bag
- 3.3 Implementing the ADT NoDuplicatesBag
- 3.4 Other Considerations
- C++ Interlude 2: Memory Allocation, Pointers, and Polymorphism
- 4. Link-Based Implementations
- 4.1 Preliminaries
- 4.2 A Link-Based Implementation of the ADT Bag
- 4.3 Testing Multiple ADT Implementations
- 4.4 Comparing Array-Based and Link-Based Implementations
- 5. Recursion: The Mirrors
- 5.1 Recursive Solutions
- 5.2 Recursion That Returns a Value
- 5.3 Recursion That Performs an Action
- 5.4 Recursion with Arrays
- 6. Recursion as a Problem-Solving Technique
- 6.1 Simplifying Complex Problems
- 6.2 Defining Languages
- 6.3 Algebraic Expressions
- 6.4 Recursion and the ADT Bag
- 6.5 Recursion and Efficiency
- 7. Algorithm Efficiency
- 7.1 What Is a Good Solution?
- 7.2 Measuring the Efficiency of Algorithms
ADTs and Algorithms for Position-Oriented Access
- 8. Stacks
- 8.1 The Abstract Data Type Stack
- 8.2 Simple Uses of a Stack
- 8.3 Using Stacks to Evaluate Postfix Expressions
- 8.4 Stacks and Recursion
- 8.5 The Relationship Between Stacks and Recursion
- C++ Interlude 3: Exceptions
- 9. Stack Implementation
- 9.1 An Array-Based Stack Implementation
- 9.2 A Link-Based Stack Implementation
- 9.3 Stack Implementations That Use Exceptions
- 10. Queues and Decks
- 10.1 The ADT Queue
- 10.2 Applications of the ADT Queue
- 10.3 The ADT Deque
- 10.4 Simple Applications of the ADT Deque
- C++ Interlude 4: Safe Memory Management Using Smart Pointers
- 11. Queue and Deque Implementations
- 11.1 Implementations of the ADT Queue
- 11.2 A Linked-Based Implementation of the ADT Deque
- 11.3 Comparing Implementations
- 12. Lists
- 12.1 Specifying the ADT List
- 12.2 Using the List Operations
- 12.3 An Interface Template for the ADT List
- 13. List Implementations
- 13.1 An Array-Based Implementation of the ADT List
- 13.2 A Link-Based Implementation of the ADT List
- 13.3 Comparing Implementations
ADTs and Algorithms for Value-Oriented Access
- 14. Basic Sorting Algorithms and Their Efficiency
- 14.1 Sorting Algorithms
- 14.2 The Selection Sort
- 14.3 The Bubble Sort
- 14.4 The Insertion Sort
- 14.5 Insertion Sort of a Linked Chain
- 14.6 The Shell Sort
- 14.7 The Radix Sort
- 15. Advanced Sorting Algorithms
- 15.1 The Merge Sort
- 15.2 The Timsort
- 15.3 The Quick Sort
- 15.4 A Comparison of Sorting Algorithms
- C++ Interlude 5: Class Relationships and Reuse
- 16. Sorted Lists and Their Implementations
- 16.1 Position-Oriented and Value-Oriented ADTs
- 16.2 Specifying the ADT SortedList
- 16.3 A Link-Based Implementation
- 16.4 Implementations That Use the ADT List
- 16.5 Efficiencies and Trade-Offs
- 17. Trees
- 17.1 Terminology
- 17.2 The ADT BinaryTree
- C++ Interlude 6: Overloaded Operators and Friend Access
- 18. Tree Implementations
- 18.1 The Nodes in a Binary Tree
- 18.2 A Link-Based Implementation of the ADT BinaryTree
- 18.3 General Tree Implementations
- 19. Binary Search Trees
- 19.1 Introduction
- 19.2 The ADT BinarySearchTree
- 19.3 AVL Trees
- 20. Implementing a Binary Search Tree
- 20.1 C++ Definitions for the Operations of the ADT BinarySearchTree
- 20.2 Saving a Binary Search Tree in a File
- 20.3 Tree Sort
- 21. Priority Queues and Heaps
- 21.1 The ADT PriorityQueue
- 21.2 Priority Queue Application: Simulation
- 21.3 The ADT Heap
- 22. Heap and Priority Queue Implementations
- 22.1 An Array-Based Implementation of a Heap
- 22.2 A Heap Implementation of the ADT PriorityQueue
- 22.3 Heap Sort
- 22.4 Introspection Sort
Advanced ADTs and Algorithms
- C++ Interlude 7: Iterators
- 23. Maps and Their Implementations
- 23.1 The ADT Map
- 23.2 Possible Implementations of the ADT Map
- 23.3 Selecting an Implementation
- 24. Hashing as a Map Implementation
- 24.1 What Is Hashing?
- 24.2 Hash Functions
- 24.3 Resolving Collisions
- 24.4 The Efficiency of Hashing
- 24.5 What Constitutes a Good Hash Function?
- 24.6 An Implementation of the ADT Map Using Hashing and Separate Chaining
- 24.7 Other Uses of Hashing in Computer Science
- 25. 2-3 Trees
- 25.1 Reprise: Binary Search Trees
- 25.2 The ADT SearchTree
- 25.3 2-3 Trees
- 25.4 Traversing a 2-3 Tree
- 25.5 Searching a 2-3 Tree
- 25.6 Adding Data to a 2-3 Tree
- 25.7 Removing Data from a 2-3 Tree
- 26. Advanced Search Trees
- 26.1 2-3-4 Trees
- 26.2 Red-Black Trees
- 27. Graphs
- 27.1 Terminology
- 27.2 Graphs as ADTs
- 27.3 Graph Traversals
- 28. Applications of Graphs
- 28.1 Topological Sorting
- 28.2 Spanning Trees
- 28.3 Shortest Paths
- 28.4 Circuits
- 28.5 Some Difficult Problems
- 29. Processing Data in External Shortage
- 29.1 A Look at External Storage
- 29.2 Sorting Data in an External File
- 29.3 Basic Data Management Operations
- 29.4 Indexing an External File
- 29.5 External Hashing
- 29.6 B-Trees
- 29.7 Multiple Indexing
- C++ Interlude 8: The C++ Standard Library
Appendices
- A. Review of C++ Fundamentals
- B. C++ File Fundamentals
- C. C++ Documentation Systems
- D. ASCII Character Codes
- E. Important Themes in Secure Programming
- F. The Unified Modeling Language
- G. Mathematical Induction
- H. Algorithm Verification
- I. C++ for Java Programmers
- J. C++ for Python Programmers
Index
Glossary (online)
Answers to Checkpoint Questions (online)
Your questions answered
Pearson+ is a one-stop shop for eTextbooks and Study & Exam Prep (also referred to as Channels), both designed to help students get better grades in college. eTextbooks and Study & Exam Prep can be purchased separately or together. eTextbooks have built-in tools that simplify studying, like flashcards, audiobook and search. Study & Exam Prep includes video lessons, practice problems, study guides, Q&A with experts and more, to help you understand tricky topics and get you prepared for test time — all in one place.
A Pearson eTextbook is an easy-to-use digital version of your assigned textbook. eTextbooks, available in Pearson+, give you access to upgraded study tools, including enhanced search, highlights and notes, customizable flashcards, and audio options for hand-free studying. Plus, you can learn on the go with the Pearson+ app.
Pearson+ offers an eTextbook rental, billed as a 6-month subscription. A subscription includes instant access to your eTextbook, including study tools such as the ability to create custom flash cards, take notes, and the option to search and highlight important info in your eTextbook. You can also bundle your eTextbook with Study & Exam Prep. When you check out, you can make a one-time, up-front payment for your eTextbook, or you can choose to pay monthly. If you opt for monthly payments, we will charge your payment method each month until your 6-month subscription ends. If something happens and you need your eTextbook for longer than 6 months, select Extend subscription on the Manage subscription page in My account at any time to continue your subscription before it ends.
A Study & Exam Prep subscription includes video lessons, practice problems and other study tools. With a subscription, you'll get unlimited access to the full range of subjects:
When you purchase an eTextbook subscription, it will last 6 months. You can renew your subscription by selecting Extend subscription on the Manage subscription page in My account before your initial term ends. If you extend your subscription, we'll automatically charge you every month. If you made a one-time payment for your initial 6-month term, you'll now pay monthly. To make sure your learning is uninterrupted, please check your card details. To avoid the next payment charge, select Cancel subscription on the Manage subscription page in My account before the renewal date. You can subscribe again in the future by purchasing another eTextbook subscription.
Channels, also referred to as Study & Exam Prep, is a video platform with thousands of explanations, solutions, and practice problems in 19 subjects to help you do homework and prep for exams. Videos are personalized to your course, and tutors walk you through solutions. Plus, interactive AI-powered summaries and a social community help you understand lessons from your class.
Channels doesn't replace traditional textbooks or eTextbooks. It's an additional tool to help you with your studies, and it can be used with Pearson textbooks or non-Pearson textbooks.
When you choose a Channels subscription, you're signing up for a 1-month, 3-month or 12-month term and you make an upfront payment for your subscription. By default, these subscriptions auto-renew at the frequency you select during checkout. You'll have access to the full video library across all 19 subjects once you've subscribed. You can bundle Channels (also referred to as Study & Exam Prep) with your eTextbook at the time of purchase. Bundle subscription terms vary. You can choose your subscription term and payment frequency at checkout.
When you purchase a Channels subscription, it will last 1 month, 3 months or 12 months, depending on the plan you chose. Your subscription will automatically renew at the end of your term unless you cancel it. We use your credit card to renew your subscription automatically. To make sure your learning is uninterrupted, please check your card details. If your payment method fails, we'll send you an email with instructions for how to update it.