liveBook · Manning

Chapter 13: Where to go next

What you will learn in chapter 13 of Grokking Algorithms, Second Edition

The chapter previews brief introductions to additional algorithms and suggests further reading based on the reader’s interests.

After this chapter you will be able to

What it builds on

Section by section

Introduction

The chapter previews brief introductions to additional algorithms and suggests further reading based on the reader’s interests.

13.1 Linear regression

The section introduces linear regression as fitting a line to data points and using it to predict a continuous value.

Key terms: linear regression, continuous

13.2 Inverted indexes

Introduces inverted indexes as a way to find which pages contain a searched word.

Key terms: hash table, inverted index, keys, values

13.3 The Fourier transform

The section introduces the Fourier transform as a way to separate a signal into components and illustrates why that is useful.

Key terms: Fourier transform, frequencies, bass, treble, MP3, JPG, digital signal

13.4 Parallel algorithms

This section explains why multicore computers make parallel algorithms valuable and why adding cores rarely produces a proportional speedup.

Key terms: multiple cores, parallel algorithm, quicksort, overhead of managing the parallelism, load balancing, Amdahl’s law, parallelizing

13.5 map/reduce

This section introduces distributed algorithms, including map/reduce, as a way to speed up very large workloads by running them across multiple machines.

Key terms: distributed algorithm, MapReduce, map/reduce

13.6 Bloom filters and HyperLogLog

This section motivates the problem of checking membership in a very large set: hash-table lookups are fast, but storing all the entries can take too much space.

Key terms: set, hash, hash tables, O(1), constant time

13.7 Bloom filters

This section explains how Bloom filters trade exact answers for low space usage when checking whether an item has been seen before.

Key terms: Bloom filters, false positives, false negatives, hash table

13.8 HyperLogLog

This section introduces HyperLogLog as a memory-efficient way to estimate the number of unique items in a large collection.

Key terms: HyperLogLog, unique elements, approximate answers

13.9 HTTPS and the Diffie–Hellman key exchange

This section explains how HTTPS uses a shared key to encrypt messages, how Diffie–Hellman lets two parties establish that key without sending it, and why fresh keys limit the damage from a compromised key.

Key terms: HTTPS, client, server, secret key, encryption, Diffie–Hellman key exchange, private key, public pattern, public key, shared secret

13.10 Locality-sensitive hashing

This section contrasts ordinary hashes with Simhash and explains why similarity-preserving hashes help find similar content.

Key terms: locality insensitive, locality-sensitive hash function, SHA-256, Simhash, duplicates, similar items

13.11 Min heaps and priority queues

This section explains how heaps expose an extreme value quickly, how repeated removal produces a sorted list, and why heaps are useful for priority queues.

Key terms: min heap, root, O(1), O(log n), heapsort, minimum value, max heap, priority queue, FIFO, highest priority

13.12 Linear programming

Introduces linear programming as maximizing an objective under linear constraints, illustrates it with two examples, and relates it to graph algorithms.

Key terms: linear programming, maximize, linear constraints, graph algorithms, Simplex algorithm

13.13 Epilogue

The epilogue encourages readers to use the book’s foundation to keep learning by exploring a topic that interests them.

Key terms: solid foundation, dive in

Concepts explained in this chapter

← Chapter 12: k-nearest neighbors

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.