mirror of
https://github.com/tiennm99/loto.git
synced 2026-07-18 14:17:30 +00:00
Soft visual constraint: no row has cols n, n+1, n+2 all filled. Implementation = constraint-aware per-row picker (uniformly samples triple-free completions of the forced+candidate set) + whole-grid rejection sampling (up to 200 attempts). Hard invariants (5 per row, 5 per col, ascending column values) are never sacrificed; if the soft constraint can't be met, the generator returns the best attempt. - src/lib/game-logic.js: hasThreeInARow, combinations, pickFilledColsOnce, pickFilledCols rejection wrapper - src/lib/game-logic.test.js: 300-trial strict assertion - docs/codebase-summary.md, project-overview-pdr.md: note the rule