Ad
  • Custom User Avatar

    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!

  • Custom User Avatar

    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?

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    It works fine now. Thanks! :)

  • Custom User Avatar

    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);

  • Custom User Avatar

    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"],
    []]