I need help with the legal move of 8 q, i need some ideas or brainstorm about moving the q from 2 diagonal (left and right) and we don't care about the bottom part.
this what i got so far :
Andres John wrote:I need help with the legal move of 8 q, i need some ideas or brainstorm about moving the q from 2 diagonal (left and right) and we don't care about the bottom part.
this what i got so far :
What, exactly, do you need help with? compiling this? running this? is it doing something you don't expect? If so, what DOES it do, and what do you EXPECT it to do?
I don't see an actual question anywhere, so nobody has any idea how to help you.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Andres John wrote:I need help with the legal move of 8 q, i need some ideas or brainstorm about moving the q from 2 diagonal (left and right) and we don't care about the bottom part.
this what i got so far :
What, exactly, do you need help with? compiling this? running this? is it doing something you don't expect? If so, what DOES it do, and what do you EXPECT it to do?
I don't see an actual question anywhere, so nobody has any idea how to help you.
i guess i need help with the compile and i was expecting the queen to backtracking, the solution requires that no two queens share the same row, column, or diagonal by checking the first row
ok...so fix that. it tells you exactly what the problem is.
On line 21, you call the legal() method, and pass it two int variables:
However, the only place you define the legal method, you say it takes THREE int variables:
The compiler is telling you that something isn't right. You either need to:
a) change the call on line 21 to pass in three arguments
b) define a new legal() method that takes two int parameters
c) change the existing legal() method to only take two - this would then require you to change any other calls to the legal() method that currently pass in three arguments.
My guess is you would want to do a, but I haven't (and most likely won't) go through your 100 lines of code to try and figure that out.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
them good ole boys were drinking whiskey and rye singin' this'll be the day that I die. Drink tiny ad.
Gift giving made easy with the permaculture playing cards