Built idea · Oct 8, 2026
Modulo Bias Microscope
Students paste a sampling function (pick a random element, shuffle, weighted choice) and the tool shows, exactly and statistically, how far its output distribution drifts from the one they intended, with a gallery of classic randomness bugs.
What it does
Shows students exactly how a common random-number shortcut quietly favors some results. Paste a small JavaScript function that turns random bits into, say, a dice roll or a card shuffle, and it works out the exact chance of every outcome (43 in 256 versus 42 in 256 for a popular dice trick), or runs a statistical test when exact counting would take too long. A gallery of seven classic bugs with fixes and a shuffle heat map are built in, and instructors can share auto-graded exercises as links. Limitation: it only reads JavaScript, and large shuffles get a statistical test instead of exact answers.