> solutions. The value of this optimization appears to be a wash; most > boards I clock under your time by 20-50%, but on the "hard board" you > clock a 20s against my "more efficient" 37s. Wild. Something about > that puzzle forces any solver to grind deep and hard, and your not > taking extra time to think about the next move pays off handsomely. Interesting... thanks... :-) > Your calculate_options method seems to do what my settle method does, > finding unsolved cells with only one option. One question I had while > reading your code, what happens if your loop finds a cell with options, > then finds a cell to settle, and settling it causes the other cell to no > longer have options (but to be settled)? have_options is never reset. I initially wanted to use have_options within brute_force, basically to tell me that the current iteration is a dead end. But then I found an easier way out, and left it at that. -- Mohit Muthanna [mohit (at) muthanna (uhuh) com] "There are 10 types of people. Those who understand binary, and those who don't."