This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*验证该列表中没有重复的数字*/ | |
valid([]). | |
valid([Head|Tail]) :- | |
fd_all_different(Head), | |
valid(Tail). | |
/*构造Puzzle*/ | |
sudoku(Puzzle, Solution) :- | |
Solution = Puzzle, | |
Puzzle = [S11, S12, S13, S14, |
NewerOlder