Sudoku Programmers Forum Index

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister   ProfileProfile   Log inLog in          Games  Calendar

Log in to check your private messagesLog in to check your private messages   

Any algorithms?

 
Post new topic   Reply to topic    Sudoku Programmers Forum Index -> Programming sudoku
View previous topic :: View next topic  
Author Message
Ali88

Joined: 01 Nov 2005
Posts: 2
:

Items
PostPosted: Tue Nov 01, 2005 2:16 pm    Post subject: Any algorithms? Reply with quote

I am creating a sudoku solver for a final year school project and i want the easiest solution possible to code and design (I am thinking a backtracking style solution).

I am only experienced in VB and have around 15 hours to design and implement the program.

I was wondering if anyone had an algorithm, source code or even any tips about the easiest way to go about this.
Any help would be greatly appreciated.
Back to top
View user's profile Send private message
Lummox JR

Joined: 07 Sep 2005
Posts: 202
:

Items
PostPosted: Wed Nov 02, 2005 5:59 am    Post subject: Reply with quote

If all you're interested in is getting the solution, then I recommend dancing links. The algorithm is described in several places around this forum, but you'll particularly find useful source code to study at http://magictour.free.fr/suexco.txt. If you can figure out that from C++ and convert the concept to VB, you'll have a pretty quick solver. Mind you, you should also check for impossible grids and for multiple solutions.
Back to top
View user's profile Send private message
dukuso

Joined: 14 Jul 2005
Posts: 424
:
Location: germany

Items
PostPosted: Wed Nov 02, 2005 10:52 am    Post subject: Reply with quote

if you don't care about speed, the easiest is just
backtracking through all 9^(81-clues) possible placements.

This usually solves a sudoku in a few seconds but
might take a few minutes for some sudokus.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Ali88

Joined: 01 Nov 2005
Posts: 2
:

Items
PostPosted: Thu Nov 03, 2005 10:07 am    Post subject: Reply with quote

Thanks for the help. Sorry if i implied i wanted to use someone elses work and put my own name on it, thats not what im after - im just not very sure how to go about this.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Sudoku Programmers Forum Index -> Programming sudoku All times are GMT
Page 1 of 1

 
Jump to:  
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
Sudoku Programmers topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group

Igloo Theme Version 1.0 :: Created By: Andrew Charron