Backtracking — The Decision Tree for Subsets & Permutations
Watch choose → recurse → un-choose. Green = a choice made, red = a choice undone, gold = a complete result emitted.
step 0
Decision tree (DFS order)
active node emitted result path taken
Partial solution
[ ]
Emitted results (0)
Press Step to begin. We explore the decision tree depth-first, making a choice, recursing, then undoing it.
Self-contained visualization. Subsets mode uses the start-index include/exclude tree (every node is a subset); permutations mode tries every unused element at each depth and emits at full length.
See junior.md for the templates and professional.md for the proof that each object is generated exactly once.