Computer Science Canada sudoku puzzle generator logical error |
Author: | xtreemboarder [ Fri Apr 21, 2006 11:07 am ] | ||
Post subject: | sudoku puzzle generator logical error | ||
I decided to try and create a SuDoKu Puzzle generator... thought it might be a challenge. Basically theres a 2D int array that holds all the numbers (obviously)... theres also a method which creates the random number and it also calls another method to check if its valid... the second method checks if theres that number in the row or column... and if there is it returns -1 and makes method 1 generate another random number (until it can be valid)... both checks work but for some reason the program ends before finishing generating all the numbers... i know i dont have the 3 by 3 square check... its ok just ignore that ill add it in later... when this starts to work.
|
Author: | xtreemboarder [ Mon Apr 24, 2006 10:49 am ] |
Post subject: | |
FOLLOW UP: how bout some help... i still dont understand why it doesnt work. |
Author: | Ultrahex [ Sun May 14, 2006 5:52 pm ] |
Post subject: | |
Ok, sure you can do it the way you are... but why not make it make the full finished one then remove the numbers that you are suppose to guess... wouldn't that make it easier to program... just a suggestion... ill get back to you on it in a bit maybe. |