Improvements to filled-grid generation. Introduced a cunning idea
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 8 Apr 2008 09:36:33 +0000 (09:36 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 8 Apr 2008 09:36:33 +0000 (09:36 +0000)
suggested by IWJ last night: grid generation can immediately choose
an entire grid row randomly, since all that's doing is nailing down
the names of the numbers, and that gets the whole thing started more
efficiently. But the main difference is that now grid generation is
given only area^2 steps to come up with a filled grid, and then cut
off unceremoniously, causing grid generation to fail and be retried
from scratch. This seems to prevent hangups on jigsaw layouts that
admit few useful solutions, by changing layout constantly. 9j
puzzles now generate at a sensible rate, and as an added bonus so do
5x5 normal puzzles, which they never used to.

git-svn-id: svn://svn.tartarus.org/sgt/puzzles@7978 cda61777-01e9-0310-a592-d414129be87e


No differences found