Peter Norvig on Solving Every Sudoku Puzzle
norvig.com
norvig.com
I realize this is the start of his search section, and he uses it as a springboard to present constrained search, but this struck me as either incorrect or an intentional straw man.
Applying even the simplest constraint (that a value cannot appear more than once in a cell) means that standard combinatorial formulas don't product accurate counts: by selecting a value, each peer has at least one cell that decrements its count of possible values (otherwise the value would have been detected by the naive algorithm). Applying constraints is the subtext of his eventual point, but I'm not seeing the value in presenting the flawed math the way he did.
The math on this really bugged me (my mind went directly to his eventual solution), and I had to go back and read the introduction to the "Search" section a couple of times to even wrap my head around what he was proposing for the "brute force" solution. Maybe its because I arrived at a solution similar to his eventual one years ago when I tackled a sudoku solver.
The other line that bothered me was: "The second choice is to somehow process much more than one possibility per machine instruction." After reading through, I understand what he means, but it's not equivalent to what he said.
This has probably worked on me too. Watching a computer play tetris had the same effect on me for that game.
Does he really imagine people solve Sudoku puzzles just to get the answer and because they are too stupid to look at the solved answer?
Do we have any other insights from these people [edited]? Perhaps why go for a walk when you did the same walk last week? Or why eat food when you're only going to go to the toilet?
And people wonder why geeks don't have friends.
EDIT for tone.
Please: "Be civil.... When disagreeing, please reply to the argument instead of calling names."
There is something in Laurie's comment. You could have focussed on why people enjoy Sudoku anyway without being rude and sarcastic.
EDIT Whereas IMHO writing a program to solve Sudoku just to prove how superior you are really is *$!%ing pointless.
That's exactly the feeling I had when I saw a computer play tetris.
I've never understood why people do Sudoku puzzles, you seem to know though. It actually seems like one of the least interesting hobbies someone can have; meaningless, rote and without any possibility of cleverness or intelligence or self improvement or improving your health or literally any other dimension that I can think of a hobby being evaluated on.
Walks at least provide fresh air, a change in environment, and a great opportunity to reflect. What exactly is the attraction of sudoku? How is it different than doing long division for fun?
Here's a tutorial application of ASP to map generation: http://eis-blog.ucsc.edu/2011/10/map-generation-speedrun/
Also, a sudoku puzzle generator directly incorporating the unique solution constraint: http://asparagus.cs.uni-potsdam.de/encoding/show/id/12739
The second is easy to correct in a live (i.e., not pedagogical) version. The first is a bit more difficult.
If you don't understand sudoku rules afterwards or cannot implement something according to a set of rules and without previous exposure, than this might be a result the interviewer is interested in as well?