Mike Lewis
Programmer
Hi All,
I'm not sure if this counts as a puzzle, but it's something that I've been trying to exercise my brain on these last few day:
What's the algorithm or formula for determining the number of legal ways of filling a Soduko grid?
Understand, I'm not interested in knowing what the number is (well, I suppose it would be slightly interesting). I would like to know how to go about calculating it.
I've got as far as saying that the first row will have 9! (factoral 9) combinations. For the second row, I'd guess there would be 9 * 2 * 3! (each of the 9 in the first row could go in one of two possible 3 x 3 squares, and for (the second row in) each square there would be 3! combinations).
After that, my brain starts hurting and I can't see how to proceed.
Anyone got any insights?
Mike
__________________________________
Mike Lewis (Edinburgh, Scotland)
My Visual FoxPro site: www.ml-consult.co.uk