Anyone written a Sudoku solver in Perl? I'd sure like to get an article about that into The Perl Review. I can barely leave the house now-a-days without seeing someone playing one of those.
Re:I did
runrig on 2006-01-04T20:35:27
There must have been something in the air. I did it too. Though it'll have to wait 'till I get home to forward it to brian.Re:I did
link on 2006-01-04T21:50:44
Sudoku solvers must be the modern day equivalent of web templating engines. I wrote one a few months ago but it is far too ugly to show anyone.
I might as well make this my home page.
My record time so far on Easy level is 2:41. Medium is somewhere between 5 and 7 minutes, can't remember. Hard and Evil scare me.
John
Simon Cozens wrote a Sudoku solver last summer.
Smylers
Re:how about generating them?
fishbot on 2006-01-06T16:24:04
I believe so... I was starting to figure out how to get my program to guage the difficulty of a given puzzle. It can already determine if a given puzzle is solvable and unambiguous. And it is easy to generate a completed matrix. The only challenge is coming up with a good strategy for deciding what to reveal as a clue and what to leave blank. Just doing it randomly and iteratively would be graceless and expensive.Re:how about generating them?
slushpupie on 2006-01-20T02:03:51
I had just picked up Sudoku when I was on the Geek Cruise with Brian a few months back and was toying with a solver then (I have a fairly well working, though slow, solver now). An interesting theory Ive seen used to generate Sudoku is to first generate a solved board. Most solvers will work on an empty board, just pick random places to "guess" and pick the first solution that comes up. After that, its just a matter of removing certain spaces. True Sudoku always has some pattern to the board, so you could use some template or some symetry rules to get a nice looking board. Difficulty can often be gauged by how many itterations of the various algorithms used are needed to complete the puzzle from a given state.