Grokking Algorithms, Second Edition

by Aditya Y Bhargava

Algorithm Data Structures

Book Details

Book Title

Grokking Algorithms, Second Edition

Author

Aditya Y Bhargava

Publisher

Manning

Publication Date

2024

ISBN

9781633438538

Number of Pages

494

Language

English

Format

PDF

File Size

7.8MB

Subject

Algorithms

Table of Contents

  • Contents
  • inside front cover
  • Praise for the First Edition
  • Grokking Algorithms
  • Copyright
  • Dedication
  • contents
  • front matter
  • foreword
  • preface
  • acknowledgments
  • about this book
  • about the author
  • Chapter 1. Introduction to algorithms
  • Binary search
  • Big O notation
  • Recap
  • Chapter 2. Selection sort
  • How memory works
  • Arrays and linked lists
  • Which is used more, arrays or linked lists?
  • Selection sort
  • Example code listing
  • Recap
  • Chapter 3. Recursion
  • Recursion
  • Base case and recursive case
  • The stack
  • Recap
  • Chapter 4. Quicksort
  • Divide and conquer
  • Quicksort
  • Big O notation revisited
  • Recap
  • Chapter 5. Hash tables
  • Hash functions
  • Use cases
  • Collisions
  • Performance
  • Recap
  • Chapter 6. Breadth-first search
  • Introduction to graphs
  • What is a graph?
  • Breadth-first search
  • Implementing the graph
  • Implementing the algorithm
  • Recap
  • Chapter 7. Trees
  • Your first tree
  • A space odyssey: Depth-first search
  • Binary trees
  • Huffman coding
  • Recap
  • Chapter 8. Balanced trees
  • A balancing act
  • Shorter trees are faster
  • AVL trees: A type of balanced tree
  • Splay trees
  • B-trees
  • Recap
  • Chapter 9. Dijkstra’s algorithm
  • Working with Dijkstra’s algorithm
  • Terminology
  • Trading for a piano
  • Negative-weight edges
  • Implementation
  • Recap
  • Chapter 10. Greedy algorithms
  • The classroom scheduling problem
  • The knapsack problem
  • The set-covering problem
  • Recap
  • Chapter 11. Dynamic programming
  • The knapsack problem (revisited)
  • Knapsack problem FAQ
  • Longest common substring
  • Recap
  • Chapter 12. k-nearest neighbors
  • Classifying oranges vs. grapefruit
  • Building a recommendations system
  • Regression
  • Introduction to machine learning
  • A high-level overview of training an ML model
  • Recap
  • Chapter 13. Where to go next
  • Linear regression
  • Inverted indexes
  • The Fourier transform
  • Parallel algorithms
  • map/reduce
  • Bloom filters and HyperLogLog
  • HTTPS and the Diffie–Hellman key exchange
  • Locality-sensitive hashing
  • Min heaps and priority queues
  • Linear programming
  • Epilogue
  • Appendix A. Performance of AVL trees
  • Appendix B. NP-hard problems
  • Decision problems
  • The satisfiability problem
  • Hard to solve, quick to verify
  • Reductions
  • NP-hard
  • NP-complete
  • Recap
  • Appendix C. Answers to exercises
  • index
  • inside back cover