A cool algorithm to check a Sudoku field?

前端 未结 25 755
清酒与你
清酒与你 2021-01-30 09:19

Does anyone know a simple algorithm to check if a Sudoku-Configuration is valid? The simplest algorithm I came up with is (for a board of size n) in Pseudocode

f         


        
25条回答
  •  深忆病人
    2021-01-30 10:11

    Peter Norvig has a great article on solving sudoku puzzles (with python),

    https://norvig.com/sudoku.html

    Maybe it's too much for what you want to do, but it's a great read anyway

提交回复
热议问题