Adversarial search: minimax & alpha-beta

Step 5 of 13 in Classical AI · Build · Medium

In two-player games, minimax assumes the opponent plays perfectly. Alpha-beta pruning skips moves that cannot change the decision, letting it search roughly twice as deep.

Build it

  1. Unbeatable tic-tac-toe

    Minimax with alpha-beta; play it in the terminal and count nodes with and without pruning.

    Done when: It never loses; pruning visits far fewer nodes.

Case study: Deep Blue vs Kasparov (1997)

  • Alpha-beta search on custom hardware, ~200 million positions per second.
  • A hand-tuned evaluation function encoded grandmaster knowledge.
  • Brute-force search worked for chess but not Go, which needed learning (AlphaGo).

Read the case study

Resources

Earn this star

On the map, you log what you built. Finish the step and its star lights.

Open this step on the map