Skip to content

Crack the Code

Deduce one original three-digit code from two compact position clues, with keyboard and touch input plus exhaustive proof that the answer is unique.

Privacy: your files never leave your device. All processing happens locally in your browser.

How to use

  1. 1.Read each clue as two separate counts: exact means correct digit and position, while wrong place means a correct digit at another position without reusing a code slot.
  2. 2.Enter three digits with the keypad or physical number keys, using Backspace or Clear guess to repair input; an incomplete Submit never spends an attempt.
  3. 3.Submit the unique code to earn exactly 1,000 points; one distinct wrong complete code is repairable, while a second distinct wrong code requires Reset run.

About Crack the Code

Crack the Code is a small deterministic deduction game built around one original Lizely fixture. The answer has three digits, and leading zeroes are part of the search space. Two clue rows describe earlier guesses. Guess 527 has two digits in their exact positions and zero correct digits in a wrong position. Guess 750 has zero exact digits and three correct digits in wrong positions. Those statements have one and only one solution among 000 through 999.

Exact means that the guessed digit equals the solution digit at the same index. Wrong place means that the digit exists in the solution but at another index. A single solution position can contribute to only one count. The scorer first removes every exact pair, then compares frequency counts for the unmatched solution and guess digits. This order prevents a repeated guess digit from reusing one solution position and inflating the wrong-place total.

The clue set is fully product-authored. It is not copied from a published puzzle, external database, branded board game, exam, or rotating challenge feed. The fixed solution is 507. Against 527, positions one and three are exact while 2 is absent, producing 2 exact and 0 wrong place. Against 750, all three digits exist but every one is displaced, producing 0 exact and 3 wrong place.

A third illustrative boundary appears in release tests. Guess 057 produces 1 exact and 2 wrong place: 7 is exact in the final position, while 0 and 5 are present but exchanged. Guess 500 produces 2 exact and 0 wrong place. Its extra 0 cannot reuse the single unmatched solution position, demonstrating why multiset accounting matters. Guess 123 produces no matches at all.

The page presents three visible slots and a ten-digit keypad. Digit buttons append from left to right until all three positions are filled. Physical keys 0 through 9 do the same. Backspace or Delete removes the final entered digit, and Enter submits. Clear guess empties only the current input. Reset run restores the entire game, including its attempt history and terminal state.

Incomplete input is safe. Submitting zero, one, or two digits reports how many positions remain but records no wrong attempt. This lets a keyboard or touch user correct an accidental early Enter without spending the finite error allowance. Non-digit programmatic input and a fourth digit are rejected atomically by the logic boundary, while the visible controls prevent both cases before submission.

A complete wrong code is recorded once. The first distinct wrong code remains repairable: clear or edit the input and try another candidate. Submitting the identical wrong code again returns the same state reference. It does not duplicate the history, consume the second error, change feedback, or alter the score. This deduplication makes rapid double-clicks and repeated Enter events harmless.

A second distinct wrong complete code deadlocks the run. At that point the unique answer is disclosed and all digit, deletion, clearing, and submit actions freeze. Completion is also terminal. Entering 507 and submitting awards exactly 1,000 points, then freezes the score, code, attempt history, and feedback. Reset run or the shared Restart control begins a clean state.

The 1,000-point result is deliberately simple. There is no speed bonus, clue multiplier, partial credit, or penalty based on which first wrong code was tried. A correct solution with no earlier error and a correct solution after one distinct wrong guess both receive the same fixed score. The value is entertainment behavior, not a standardized reasoning measurement.

Uniqueness is proven independently. The product includes a pure scorer and a candidate enumerator, but the release test does not accept them as their own oracle. It defines a separate literal clue table, implements separate exact removal and unmatched frequency maps, zero-pads each integer from 0 through 999, and filters all 1,000 candidates. That independent traversal returns only 507.

The tests compare the production result with that one-element oracle set and also cover the scoring boundaries above. State tests prove incomplete safety, first-error repair, identical-error atomicity, second-distinct-error deadlock, leading-zero entry, deletion, digit-cap enforcement, invalid-character rejection, full reset shape, exact score, and frozen terminal states. Each explicit behavior has a concrete assertion rather than relying on a visual impression.

The interface is accessible without color. Clues state their counts in text, slots show a digit or underscore, distinct wrong codes are listed, and status copy gives both used errors and entered digits. All keypad buttons have native semantics and at least a touch-friendly minimum height. Five columns fit comfortably at a 390-pixel viewport without page overflow. Focus styling and live feedback use the shared site components.

The shared double-Escape Boss Mode temporarily replaces the puzzle with a neutral spreadsheet view. Returning from Boss Mode preserves the same code, wrong history, score, and terminal status. Repeated keyboard events are ignored at the UI layer, while state-level deduplication provides a second guard for repeated complete guesses.

Everything runs locally in the browser. No code guess, clue interaction, score, or keyboard event is uploaded. No account, paid service, network request, random generator, or new runtime dependency is used. Because the complete fixture is bundled and finite, the same clue rows and unique answer remain available offline after the page loads.

Crack the Code is recreational entertainment. It is not an intelligence test, aptitude measure, classroom placement tool, hiring screen, health instrument, or psychological assessment. The solution and exhaustive proof are disclosed in the page methodology, so repeated play becomes trivial. For an unaided solve, start with the clue showing that 7, 5, and 0 are all present but displaced, then use the two exact positions in 527 to determine their order.

Methodology & sources

Store the original solution 507 and clues 527 with 2 exact and 0 wrong-place, plus 750 with 0 exact and 3 wrong-place. Score a candidate by removing exact positions, counting remaining digit frequencies, and summing per-digit frequency minima for wrong-place matches. Independently implement the same stated rule in a separate test oracle and enumerate every zero-padded candidate from 000 through 999; exactly one candidate, 507, satisfies both clues. Keep incomplete submissions penalty free, deduplicate an identical complete wrong code as an identical-state no-op, allow one distinct wrong code, deadlock on the second, award exactly 1,000 for the unique solution, and freeze both terminal states until reset.

Frequently asked questions

Are leading zeroes allowed?
Yes. The independent proof checks every zero-padded code from 000 through 999, so a leading zero is a normal digit position.
Can repeated digits be counted twice?
Only when separate unmatched solution positions support them. Exact pairs are removed first, then wrong-place counts use the minimum remaining frequency for each digit.
Does the 1,000-point score measure reasoning ability?
No. The original fixed fixture, finite error rule, disclosed solution, and exact score are recreational product behavior, not a standardized intelligence, education, employment, health, or psychological assessment.

Mini Games guides

View all