Number Guessing Game
Classic guess-the-number game with hints, optimal binary search analysis, and a reverse mode where the computer guesses your number.
About this tool
Play the classic number guessing game with a twist — after you solve it, the game shows the binary search strategy that would have found the number in the minimum possible guesses. Choose Easy (1–50), Medium (1–100), or Hard (1–1000) difficulty, or set a fully custom range. The computer picks a secret random number; you guess and receive 'too high' or 'too low' feedback until you find it. A visual history list tracks every guess and narrows the displayed range in real time. The info panel always shows how many guesses you've used and the theoretical minimum (⌈log₂ n⌉). After solving, an animated walkthrough demonstrates the optimal binary search path step by step. In Reverse Mode, you think of a number and the computer guesses it using binary search — you only reply Higher, Lower, or Correct. Perfect for understanding algorithmic thinking and search complexity.
How to use
- 1 Choose a difficulty (Easy, Medium, Hard) or set a custom min/max range.
- 2 Type your guess in the input field and press Enter or click Guess.
- 3 Read the 'Too High' or 'Too Low' hint and use the narrowing range display to plan your next guess.
- 4 Continue guessing until you find the number — your guess count is tracked throughout.
- 5 After solving, click 'Show Optimal Strategy' to see the binary search walkthrough.
- 6 Try Reverse Mode: think of a number and let the computer find it using binary search.
Frequently Asked Questions
Roll polyhedral RPG dice using standard notation like 2d6+1d8+5.
Roll dice, flip coins, draw random cards, and generate random numbers — all cryptographically random.
Classic card-flip memory matching game with emoji themes, multiple grid sizes, and best-score tracking.
Visualize the Fibonacci sequence, animated golden spiral, and ratio convergence toward φ.