# TAOCP Vol 2 review

> Study guide to TAOCP Vol 2 review. A review week for Volume 2: random numbers and arithmetic.

Updated October 20, 2026.

## Summary {#summary}

TAOCP Vol 2 review: A review week for Volume 2: random numbers and arithmetic. Budget about 5 hours; do exercises 3.1-23, 3.2.2-16 and 3.4.1-16.

## Key facts {#key-facts}

- Week 89 of 145 on the cracked.guide path, in [TAOCP Vol 2: Seminumerical Algorithms](https://cracked.guide/taocp/volume-2).
- Time budget: about 5 hours.
- 918 exercises in the section, rated 00 to HM50; the guide picks 8.
- Picked exercises with Knuth's triangle for recommended: 3.1-23, 3.2.2-16, 3.4.1-16, 4.2.2-30, 4.3.1-21, 4.5.2-38, 4.5.4-41 and 4.6.4-38.
- Before you start: all of Vol 2.

## Week 89 goals {#objectives}

By the end of week 89 you can:

- Implement multiplication and reciprocal of truncated power series.
- Use power series reversion to invert a series like z = t/(1 + t).
- Compare your Volume 2 code against Knuth's practical advice.

## This week's steps {#steps}

- Read §Vol 2 review: Tidy up the code you wrote: PRNGs, tests, bignums, gcd, factoring.
- Work the exercises (8 picked): Start with Ex 3.1-23, Ex 3.2.2-16, Ex 3.4.1-16; log what you solve below.
- Write down one thing you'd explain to someone: A few sentences in your own words in Your notes: the idea, why it works, an example. 30 words ticks this.

## Exercises {#exercises}

Vol 2 has 918 exercises in all, rated 00 to HM50, and about 240 of them carry Knuth's triangle for recommended. Use the week to finish ones you skipped, or try this mixed set, which you have not seen in the weekly picks: one or two from each part of the volume, referenced as section-number.

Worth your time:

- 3.1-23 (rated M26, recommended): Encode every mapping as a sequence with a bijection. Combinatorial review.
- 3.2.2-16 (rated M28, recommended): Show that the shift-register method produces a linear recurrence mod 2.
- 3.4.1-16 (rated HM22, recommended): Design a rejection sampler for gamma deviates of small order.
- 4.2.2-30 (rated M30, recommended): Explain wildly wrong calculator results on a harmless-looking function. Floating-point review.
- 4.3.1-21 (rated M23, recommended): How rarely the corrected trial quotient is still wrong.
- 4.5.2-38 (rated M32, recommended): Make the binary gcd fast for big numbers, Lehmer-style.
- 4.5.4-41 (rated M28, recommended): Count primes faster than finding them all.
- 4.6.4-38 (rated HM32, recommended): Prove that Horner's rule is optimal when coefficients are not preprocessed.

## Why it matters {#why}

Vol 3 leans on probability (from chapter 3) and on the analysis style you practiced. A quick review makes the switch smoother.

## Before you start {#before}

- All of Vol 2

## How to approach it {#approach}

Tidy up the code you wrote: PRNGs, tests, bignums, gcd, factoring. Put it in one repo with tests. Write a one-page summary of what to use in practice for random numbers and for big arithmetic.

## Common traps {#traps}

- Skipping review. This is the halfway point of the whole path.

## Links {#links}

- [Knuth's TAOCP page (editions, errata, MIX/MMIX)](https://www-cs-faculty.stanford.edu/~knuth/taocp.html)
- [Vol 2 errata (plain text, from Knuth)](https://www-cs-faculty.stanford.edu/~knuth/err2.textxt)

---

Source: https://cracked.guide/guide/knuth-w072-1
cracked.guide: A free, dated 145-week path to getting genuinely cracked at programming.
