Win a copy of Machine Learning Systems: Designs that scale this week in the Scala forum
or Xamarin in Action: Creating native cross-platform mobile apps in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Need a bit of help suduko  RSS feed

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to create a program for class to either create a suduko or to solve one.
I leaning towards creating them since it seems easier any help would be appreciated. I am still new to this language so be gentle
 
Ranch Hand
Posts: 1923
Linux Postgres Database Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What do you have so far?
Did you think of an appropriate datastructure to store your sudoku?
What methods will you need?
 
Ranch Hand
Posts: 547
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
probably solving is easier...because it can be done with a brute force/recursive algorithm (try and error)

when you create a sudoku, then you need to make sure that it can be solved... which you do by solving it....


as stefan said: think about a datastructure... this will make it easier
show us what you've done so far and then we can help you out...

pascal
 
Jared Upton
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I haven't even started all I have done is look at some other examples. This may be a bit above my head but it seems interesting. I was thinking of using an arraylist. But still trying to figure out how to work with a 9 by 9 grid and figure out how to get the answer by brute force.
 
Danger, 10,000 volts, very electic .... tiny ad:
Rocket Oven Kickstarter - from the trailboss
https://coderanch.com/t/695773/Rocket-Oven-Kickstarter-trailboss
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!