Ad
  • Default User Avatar

    Thank you for the changes and prompt reply!

  • Custom User Avatar

    I changed the tests to give a somewhat bettwer feedback, but infortunately your solution fails only for longer inputs so it can be not that easy to debug. However, I found out that your solution fails following test case:

    assert.strictEqual(nameInStr('Betty', 'Betty'), true);
    

    Additionally, you are handling letter case incorrectly: "case-insensitive" means that lowercase letters and uppercase letters should be treated as the same.

    Yoru solution is buggy, it's not a kata issue.

  • Default User Avatar

    From Output:

    Expected: true, instead got: false

    Log

    [ 'ocll tottcnydlj yxp yajneqiybj axeeberr y kyttidbirsiyem hmjjlrijr jalci ii ts r',
    'Alexandria' ]


    Sorry, I don't understand why we should end up with "true".

    "Letter comparison should be case-INsensitive."

    And there is no "A" in the "str".

    And even if we forget about letter case, the letters are not in the right order:

    'ocll tottcnydlj yxp yAjneqiybj axeeberr y kyttidbirsiyem hmjjLrijr jalci ii ts r'