Ad
  • Custom User Avatar

    Your example should absolutely return false, but I doubt that the random test cases are wrong. They have been checked a lot of times already.

    There is a problem with your code, though. And there isn't a specific test case to catch that particular bug. (Wish I could add test cases after the kata was published.) With a bit of (bad?) luck, the random tests won't expose it either.

    Try running your code on isMerge('ananas', 'anas', 'na'). It should return true.

    Thanks for your feedback! :-)

  • Custom User Avatar

    Your "random string" test cases often expect true when they should be false. If the same character exists at a given char position in part1 and part2, it expects true, but should be false. I passed by re-submitting a few times until this stopped happening, receiving different numbers of failed tests each time

    e.g. s="test;ab", part1="te;a", part2="st;b" - expects true but should be false (at least that's my interperetation of the problem!)