flat assembler
Message board for the users of flat assembler.

Index > Projects and Ideas > fast sudoku solver in windows

Author
Thread Post new topic Reply to topic
tthsqe



Joined: 20 May 2009
Posts: 730
tthsqe
I'm working on a fast sudoku solver in fasm. It should be really fast...
Can anyone point me in the right direction for a simple user interface? I would like to input 9 rows of characters to the program from some kind of dialog box.
Post 11 Jul 2009, 09:35
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17716
Location: In your JS exploiting you and your system
revolution
There is already a GUI with solver for sudoku posted to this board a few years ago. If you can't find it with the site search then I think I have the file somewhere in my backup.

BTW: Sudoku is really easy to solve with the CPU in less than a milli-second. The speed is not really an issue unless you are solving thousands of grids each second? Confused
Post 11 Jul 2009, 09:43
View user's profile Send private message Visit poster's website Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17716
Location: In your JS exploiting you and your system
revolution
Post 11 Jul 2009, 10:22
View user's profile Send private message Visit poster's website Reply with quote
tthsqe



Joined: 20 May 2009
Posts: 730
tthsqe
I'm talking on the order of tens of microseconds or less for normal sudokus. It's build for speed. Some sudokus are not so easy, though. Take this one:

Code:
.......39
.....1..5
..3.5.8..
..8.9...6
.7...2...
1..4.....
..9.8..5.
.2....6..
4..7.....    


Brian Turner has a C program that solves it in about 800 microseconds, and I am wondering what kind of speed up one can get in assembly using slightly different algorithms/data structures.
Post 11 Jul 2009, 18:03
View user's profile Send private message Reply with quote
tthsqe



Joined: 20 May 2009
Posts: 730
tthsqe
by normal sudokus I mean the ones humans can be expected to solve
Post 11 Jul 2009, 18:07
View user's profile Send private message Reply with quote
tthsqe



Joined: 20 May 2009
Posts: 730
tthsqe
Also, the faster one can solve, the faster one can generate quality sudoku puzzles. The solver in the link above seems to be very slow.
Post 11 Jul 2009, 18:10
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17716
Location: In your JS exploiting you and your system
revolution
tthsqe wrote:
Also, the faster one can solve, the faster one can generate quality sudoku puzzles. The solver in the link above seems to be very slow.
Yes, it is slow, but you asked for a UI, and that is what I linked to.
Post 11 Jul 2009, 23:54
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.