From: Ken Bloom Date: 2008-11-14T14:37:22+09:00 Subject: Re: [SUMMARY] Sudoku Generator (#182) On Thu, 13 Nov 2008 11:10:54 -0500, Matthew Moss wrote: > The final step is to take the "solved" puzzle and poke holes in it, > enough so we have a real puzzle for humans to solve. Again, this is > quite simple: > > 64.times{puzzle[rand(81)] = 0} > > This line will punch at most 64 holes into the puzzle. 64 is chosen as > the upper limit, since there seems to be some evidence that the [Minimum > Sudokus][2] -- puzzles uniquely solveable with the least number of clues > -- seems to require 17 clues (and 81 - 17 = 64). It is quite likely, > however, that there will be some overlap in the hole choices, and so > there will likely be more than 17 clues: fewer holes means more clues, > which means (generally) an easier puzzle. This will punch out, on average, 44 holes. -- Chanoch (Ken) Bloom. PhD candidate. Linguistic Cognition Laboratory. Department of Computer Science. Illinois Institute of Technology. http://www.iit.edu/~kbloom1/