Sudoku

Got a brilliant program idea? Let us know!

Moderator: MaxCoderz Staff

Liazon
Calc Guru
Posts: 962
Joined: Thu 27 Oct, 2005 8:28 pm

Post by Liazon »

huh? how does studying a sudoku solver help? I thought I was just trying to generate one and then write an interface of some sort. Then again, at least it tells me if the generated sudoku will have a unique solution. I duno what I'm going to do about difficulty though. I should probably google "generating sudokus" and see if I can find out more.
Image Image Image
katmaster
Sir Posts-A-Lot
Posts: 252
Joined: Tue 09 Aug, 2005 9:34 pm
Location: south of the north pole
Contact:

Post by katmaster »

Are you gonna do it? That'd really be friggen' awesome. I know a lot of people who love sudokus and would love to see them on calcs.
cheese=yum
Image
Liazon
Calc Guru
Posts: 962
Joined: Thu 27 Oct, 2005 8:28 pm

Post by Liazon »

I'm going to try, but that doesn't mean I'm going to succeed.

I've only made one ASM program so far anyways (one which i'm still not 100% sure works).

But if kv83 wanted to do it, he can go rite ahead.
Image Image Image
User avatar
kalan_vod
Calc King
Posts: 2932
Joined: Sat 18 Dec, 2004 6:46 am
Contact:

Post by kalan_vod »

User avatar
kv83
Maxcoderz Staff
Posts: 2735
Joined: Wed 15 Dec, 2004 7:26 pm
Location: The Hague, Netherlands
Contact:

Post by kv83 »

I've some other projects atm, but I'll make one, whether you try or not... Besides, I already got the Sudoku algorithme done... so I'm one step ahead of you :twisted:
Image
Nick the Wizard
New Member
Posts: 1
Joined: Tue 03 Jan, 2006 4:14 am

Post by Nick the Wizard »

There are a couple problems with writing a Sudoku program. First of all, I don't think you can generate just any Soduku puzzle. I'm pretty sure there are a lot of possible random boards that would be unsolvable. There should be ONLY one spot for every number, whether it is apparent quickly or through a recursive function. The current Sudoku electronic games I've seen just use ones that are programmed in. IF you make such a game, it'd be important to make a testing algorithm to make sure that such a board is solvable.
threefingeredguy
Calc King
Posts: 2195
Joined: Sun 27 Mar, 2005 4:06 am
Location: sleeping
Contact:

Post by threefingeredguy »

There has been one made already. Feel free to discuss it here.
Image
Liazon
Calc Guru
Posts: 962
Joined: Thu 27 Oct, 2005 8:28 pm

Post by Liazon »

And welcome to MC!
Image Image Image
User avatar
kalan_vod
Calc King
Posts: 2932
Joined: Sat 18 Dec, 2004 6:46 am
Contact:

Post by kalan_vod »

Nick the Wizard wrote:There are a couple problems with writing a Sudoku program. First of all, I don't think you can generate just any Soduku puzzle. I'm pretty sure there are a lot of possible random boards that would be unsolvable. There should be ONLY one spot for every number, whether it is apparent quickly or through a recursive function. The current Sudoku electronic games I've seen just use ones that are programmed in. IF you make such a game, it'd be important to make a testing algorithm to make sure that such a board is solvable.
Yeah, what you say about randomly generating boards would be quite difficult, unless one generates a board then checks for a solution and if it isn't possible make changes to it, which would make it work.
Liazon
Calc Guru
Posts: 962
Joined: Thu 27 Oct, 2005 8:28 pm

Post by Liazon »

I wonder how slow that could be.
Image Image Image
User avatar
kalan_vod
Calc King
Posts: 2932
Joined: Sat 18 Dec, 2004 6:46 am
Contact:

Post by kalan_vod »

calcul831415 wrote:I wonder how slow that could be.
Well in asm it wouldn't take too long, but it would be rather slow in basic :P.
lecks
Extreme Poster
Posts: 484
Joined: Fri 09 Sep, 2005 1:56 am

Post by lecks »

can't the calculator sutomatically make a complete board and then choose some numbers to keep and take the rest away and then show you the puzzle and let you solve?
Liazon
Calc Guru
Posts: 962
Joined: Thu 27 Oct, 2005 8:28 pm

Post by Liazon »

You could take a solved board and use random algoritms to switch rows and columns and rotate the board to make new solvable puzzles. The only issue is which numbers you can take out. Take out too many, it's impossibly annoying. Take out too few, it's way too easy. Like 3FG said, a sudoku game has already been made.
Image Image Image
User avatar
kalan_vod
Calc King
Posts: 2932
Joined: Sat 18 Dec, 2004 6:46 am
Contact:

Post by kalan_vod »

calcul831415 wrote:You could take a solved board and use random algoritms to switch rows and columns and rotate the board to make new solvable puzzles. The only issue is which numbers you can take out. Take out too many, it's impossibly annoying. Take out too few, it's way too easy. Like 3FG said, a sudoku game has already been made.
Well it seems like it would work as you are saying, the difficulty setting would decide if it changes how many sections. I think this topic is about making randomizing boards now :P.
CompWiz
Calc King
Posts: 1950
Joined: Thu 13 Oct, 2005 1:54 pm
Location: UB

Post by CompWiz »

Well, taking numbers away could make it too easy or completely unsolvable, if you removed them randomly. You would have to check to see if removing a number makes another solution possible, and somehow check to see how "hard" a puzzle is, if that is even possible.

I got a series of sudoku puzzle books for christmas, and started working on a basic program that would solve them. It would basically store all the possible values that could be used in each space, then eliminate the possibilities until you only had one possibility for each space.

I got a few parts of the program done, and it was going pretty well, but I lost interest, and I really have an obligation to learn asm for the n-game project.

If anyone wants the code I got so far(I didn't get all that far, but I almost got to the point of having the first solving algorithm working), let me know and I can upload it. Just so there's no surprises, I'm not very good at optimizing. It's like I have the wrong mindset or something. :D
In Memory of the Maxcoderz Trophy Image
Post Reply