tito.plauto - did you find the solution of this? Because I currently have the same problem.
The strange thing that when I'm copying this matrix and trying to test it it works, but it fails during the attempts
Hi, thanks for the answer but I don't think you got the problem (or maybe I don't get your answer). I know that table isn't regular and my program recognizes it too, but only if I reorganise the input of the test as an array of arrays, as it should be. I'm thinking the problem might be that that input given by the test isn't an array as the others, but something else. I can't understand what type of data is that: it has spaces, so it isn't a number, but it hasn't the quotes, then it isn't a String.
Good day. The order from 1 to 9 should be horizontal and vertical at the same time. This rule is the main idea of the game. If you look on the first column of your "table", you will see, that all values are equal to '1', instead of being in order from '1' to '9'
Hi, can someone explain me why it expects this to be 'true'? And what does that 'pre' mean? And why the input isn't an array? My function seems to work on other tests. Thanks a lot
The input is always an array of arrays, and you can see that printing the input.
No, I'm sorry, I just gave up after infinite tries
tito.plauto - did you find the solution of this? Because I currently have the same problem.
The strange thing that when I'm copying this matrix and trying to test it it works, but it fails during the attempts
Hi, thanks for the answer but I don't think you got the problem (or maybe I don't get your answer). I know that table isn't regular and my program recognizes it too, but only if I reorganise the input of the test as an array of arrays, as it should be. I'm thinking the problem might be that that input given by the test isn't an array as the others, but something else. I can't understand what type of data is that: it has spaces, so it isn't a number, but it hasn't the quotes, then it isn't a String.
Good day. The order from 1 to 9 should be horizontal and vertical at the same time. This rule is the main idea of the game. If you look on the first column of your "table", you will see, that all values are equal to '1', instead of being in order from '1' to '9'
Ok, thanks. Edit: I wrote that same input as an array of arrays:
console.log(validSolution([[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9],
[1, 2, 3, 4, 5, 6, 7, 8, 9]]))
and the result is "false".
Obviously if I do this:
console.log(1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9)
it gives error. Do someone have an idea?
You're misreading the logs, that test expects false. Read this: https://docs.codewars.com/training/troubleshooting/#print-input
Hi, can someone explain me why it expects this to be 'true'? And what does that 'pre' mean? And why the input isn't an array? My function seems to work on other tests. Thanks a lot
Expected 'true' on input of
: expected false to equal true