Ad
  • Custom User Avatar

    As I have explained, wkppvixoyxzzzzzzzzzzzz is not valid because between ixoyx and zzzzzzzzzzzz there's 3452 which your code should read because the kata asks you for the longest k consecutive strings. Consecutive is when they are following one another in uninterrupted sequence/order.

  • Custom User Avatar

    Your solution skipped 3452, going directly for zzzzzzzzzzzz. You shouldn't be able to do that considering it should be consecutive strings.

    From the array, the possibilities are:

    ["it", "wkppv", "ixoyx", "3452", "zzzzzzzzzzzz"]
     ___________1__________
           _____________2__________
                    _______________3_______________
    
    1. "it", "wkppv", "ixoyx" (length 12)
    2. "wkppv", "ixoyx", "3452" (length 14)
    3. "ixoyx", "3452", "zzzzzzzzzzzz" (length 21)

    Therefore, the answer is "ixoyx3452zzzzzzzzzzzz".

    Not a kata issue.