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.
Looks like you solved it, closing ~~
Hopefully fixed that, but unless otherwise specified, it is always better never to change the starting array.
So, there are 13 'O', 22 'A', 23 'W', 24 'H' in the input data, but 15 'O', 26 'A', 29 'W', 25 'H' in expected result. I don't get it... Maybe I misunderstood something? This is JavaScript version.
Input: [ [ 'A', 'H', 'O', 'H', undefined, 'A', 'H', 'A', 'W', undefined ],
[ 'A', 'W', 'H', 'A', 'O', 'A', 'W', 'H', 'W', 'O' ],
[ 'W', 'W', undefined, 'W', 'H', undefined, 'A', 'H', 'W', 'H' ],
[ 'W', undefined, 'O', 'W', undefined, 'A', 'W', 'A', 'A', 'H' ],
[ 'W', 'H', 'O', undefined, 'H', undefined, 'H', 'H', 'O', 'A' ],
[ 'O', undefined, 'H', 'H', 'W', 'A', 'H', undefined, 'A', undefined ],
[ 'O', 'H', 'W', 'A', 'O', 'A', 'H', 'H', 'W', 'A' ],
[ 'A', 'O', undefined, 'H', undefined, 'O', 'H', 'W', 'A', 'H' ],
[ 'H', 'W', 'A', undefined, 'W', 'A', 'W', 'W', 'O', 'O' ],
[ 'A','W',undefined,undefined,'W','H','W',undefined,undefined,'A' ] ]
Expected: [["O","O","O","O","O","O","O","O","O","O"],
["O","O","O","O","O","A","A","A","A","A"],
["A","A","A","A","A","A","A","A","A","A"],
["A","A","A","A","A","A","A","A","A","A"],
["A","W","W","W","W","W","W","W","W","W"],
["W","W","W","W","W","W","W","W","W","W"],
["W","W","W","W","W","W","W","W","W","W"],
["H","H","H","H","H","H","H","H","H","H"],
["H","H","H","H","H","H","H","H","H","H"],
["H","H","H","H","H"]],
instead got: [["O","O","O","O","O","O","O","O","O","O"],
["O","O","O","A","A","A","A","A","A","A"],
["A","A","A","A","A","A","A","A","A","A"],
["A","A","A","A","A","W","W","W","W","W"],
["W","W","W","W","W","W","W","W","W","W"],
["W","W","W","W","W","W","W","W","H","H"],
["H","H","H","H","H","H","H","H","H","H"],
["H","H","H","H","H","H","H","H","H","H"],
["H","H"],
[]]
This comment is hidden because it contains spoiler information about the solution
Done! :) TY
Just for your description change the last sentence to
"Psst! Ask Pitagoras for more information, but don't tell him I sent you :)"