Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Not a valid Sudoku answer. Each 3x3 section has to have the digits 1-9.
Top left 3x3 section should contain 1-9:
5, 3, 1
6, 2, 3
1, 9, 1
It contains 1 three times, 3 twice, and it's missing 4, 7, and 8.
Top middle contains 7 twice and misses 8; top right misses 1 and 3 and has 4 and 8 twice; etc.
I ran into a problem. The test puzzle isn't deterministic.
My solver found this solution from your test case:
[ 5, 3, 1, 2, 7, 6, 4, 9, 8 ]
[ 6, 2, 3, 1, 9, 5, 8, 4, 7 ]
[ 1, 9, 8, 3, 4, 7, 5, 6, 2 ]
[ 8, 1, 2, 7, 6, 4, 9, 5, 3 ]
[ 4, 7, 9, 8, 5, 3, 6, 2, 1 ]
[ 7, 4, 5, 9, 2, 8, 3, 1, 6 ]
[ 9, 6, 7, 5, 3, 1, 2, 8, 4 ]
[ 2, 8, 6, 4, 1, 9, 7, 3, 5 ]
[ 3, 5, 4, 6, 8, 2, 1, 7, 9 ];
It's a valid Sudoku answer, but it doesn't work when validated against the specific result you're looking for. Similar problems occur when submitting the solution and comparing against the other test cases. Validation should really be testing for any valid solution rather than a specific solution.
This comment is hidden because it contains spoiler information about the solution
This incorrectly trims the string. e.g: "12 " would return true. You need another way to handle the spaces.
Also add ))(( as a test case as several solutions incorrectly sum up the number without validating position.