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.
Sorry, I totally forgot about "shift" parameter. :( So there was a problem with initial shift - it was always 1.
BTW, I can't see "spoiler" comments until I solve the puzzle... :) But thanks anyway!
Yes, there is a space. Space is 1st symbol. Second - "u". So, shift for "u" must be 2, "u"+2="w", not "x", isn't it? Or I misunderstood something?
This comment is hidden because it contains spoiler information about the solution
It works fine now. Thanks! :)
If so, case insensitivity must be explicitly mentioned in kata details, I think. Or at least it must be clear after looking at test cases.
I.e. Test.assertEquals(validateHello('Halloween'), true);
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"],
[]]