Loading the experience.

Taking a little longer. You can keep browsing.

A small puzzle.
A visible process.

Match the digits. Build a chain. Then watch search find what you missed.

Illustrative overlap puzzle inspired by my Digit-Fragment Puzzle Solver. This teaching version has its own explicit rules; it is not a verified port of the original Python project.

Current example: Branching loop. Join pieces when their boundary digits match.

Fragments

Select a piece, then append it. Each piece can be used once.

Your chain

Choose a starting piece.

No pieces yet.

Enable JavaScript for the interactive player. The rules and an example solution are below.

What makes a good answer?

  1. Match the last digit of your chain with the first digit of the next piece.
  2. Use each labelled piece once. Identical digits on different pieces still count separately.
  3. Use as many pieces as possible. Equal answers are resolved by the alphabetical sequence of piece IDs, A–H.

The solver indexes pieces by their first digit, explores possibilities with depth-first search and backtracks when a path ends. Its pruning bound deliberately overestimates remaining choices; it only cuts a branch when even that bound is strictly shorter than the current best.

Counts report this teaching algorithm's actual visited states and cuts. Playback speed changes how you watch, not what the solver computes.

Explore my full-stack work →