I'd use a deductive method to solve the puzzle. Start with nine times as many cells, with 1-9 repeating, counting each set of nine as the possible values for one cell and eliminate all impossible choices until only one remains.
can we actually solve sudoku in reasonable time using this algorithm? I have built a program myself using this algorithm and as soon as I did so it struck me that if we start with a sudoku that has got no solutions e.g. 1,1,......... we will have to try out ALL(!) of the 9^79 combinations to be sure that it really is unsolvable. Therefore, I believe on average will take ages for the offered algorithm to solve a problem. Please correct me if I am wrong.
What you're suggesting is in fact quite impossible (you're right to suspect that), but that's by far not the only way to solve a puzzle. The way I tend to solve the puzzle is using the same method a human would do it: have the program go through all blank pieces and check to see if there is enough information to solve it. Keep checking them and solving pieces that have info until you finish. If it can't be solved this way then a human can't solve it either.
Richard discusses most complex function in this program, which is hasSolution, at 34:19 // hasSolution does most solving work, so solution can be later displayed.
This has been flagged as spam show
He's funny and very brilliant.
katheryncruz24 1 month ago
He's got a lot of points to remember. He's funny too.
jhamien920 2 months ago
I'd use a deductive method to solve the puzzle. Start with nine times as many cells, with 1-9 repeating, counting each set of nine as the possible values for one cell and eliminate all impossible choices until only one remains.
axelasdf 5 months ago
@axelasdf I do think this idea may have some flaws.
axelasdf 5 months ago
can we actually solve sudoku in reasonable time using this algorithm? I have built a program myself using this algorithm and as soon as I did so it struck me that if we start with a sudoku that has got no solutions e.g. 1,1,......... we will have to try out ALL(!) of the 9^79 combinations to be sure that it really is unsolvable. Therefore, I believe on average will take ages for the offered algorithm to solve a problem. Please correct me if I am wrong.
vladimirkovalev1990 1 year ago
@vladimirkovalev1990
What you're suggesting is in fact quite impossible (you're right to suspect that), but that's by far not the only way to solve a puzzle. The way I tend to solve the puzzle is using the same method a human would do it: have the program go through all blank pieces and check to see if there is enough information to solve it. Keep checking them and solving pieces that have info until you finish. If it can't be solved this way then a human can't solve it either.
Truthiness231 1 year ago
Someone steals his Mars Bar at 15:08
BestTypoEver 1 year ago
HOW DO ALGORITHM?
looni3 1 year ago 2
man he's good!
i have been watching Richard's video for a whole day.
wish i can download it instead of on youtube...
reitube2 1 year ago
@reitube2 you can download...use firefox, and get an add on called video download helper..works a treat....very easy to use
MrBlaxjax 1 year ago
"I won't stick it in if it's not legal!"
Good idea!
spitball123 1 year ago 17
i noticed that some of these are in HQ while others arnt will they all eventually be HQ? i cant read alot of the things on the screen :(
ramblinevilmushroom 2 years ago 4
Richard discusses most complex function in this program, which is hasSolution, at 34:19 // hasSolution does most solving work, so solution can be later displayed.
extension1337 3 years ago 6
Richard discusses most complex function in this program, which is hasSolution at 34:19.
extension1337 3 years ago