Ad
  • Custom User Avatar

    Well, I'll give you this at least: when you finish this kata you really feel like you earned it. :D

  • Custom User Avatar

    Many thanks, both have been approved. :)

  • Custom User Avatar

    Nice kata! I've rated it. :)

    As suggested below I think this kata needs more test cases, and some random ones. I'm happy to come back and approve it when you add some.

    Test.expect() is an old method that is generally frowned upon for testing now. You can use Test.assertEquals() to test strings. See here for more info.

  • Custom User Avatar

    I've rated and approved. :-)

    I have one suggestion. My first solution passed even though it only removed lower case 'a' and 'e'.
    The second time the random case caught it out. I'd suggest adding a test case that includes 'A' and 'E' or make it so that the random test case includes at least one uppercase letter, or you could add more random test cases.

    Nice kata either way!

  • Custom User Avatar

    Great, thanks!

    I will have to try and come up with something more devious to one-line it seems then. ;)

  • Custom User Avatar

    Thank you for the suggestion, and I'm glad you liked the kata (very impressive one-liner!). I will be sure to modify the test cases as soon as I get a chance today.

  • Custom User Avatar

    Nice beginner's kata. I'm guessing this is an old project you're unlikely to come back to, but this needs random test cases, and some user test cases.

  • Custom User Avatar

    It's not possible to totally anti-cheat this as you've paired it with an easier version of the problem. Someone only needs to solve the easy version and copy+paste solutions they find there.

    Rated/ approved as I learnt a few interesting things with this one, thanks!

  • Custom User Avatar

    Nice kata! I enjoy these short limitation challenges and will try the hard version. Rated and approved.

  • Custom User Avatar

    My pleasure I'm glad you liked it, and thanks a lot! I've accepted the translations. :-)

  • Custom User Avatar

    Thank you for getting back to me. I will be sure to try this again soon in that case.

  • Custom User Avatar

    When my solution uses sort off-site on the last test case it sorts the array in the appropriate order and returns the correct answer. Here it sorts the array in the wrong order and returns the wrong answer.

    Is sort disabled for this kata? If so, I'd suggest mentioning it in the description as its a little needlessly confusing otherwise.

  • Custom User Avatar

    Thanks for the kata, I enjoyed it. I only noticed one small bug. My code seems to always fail the first sample test case when I press 'run tests', even though it passes all the tests on submission.

  • Custom User Avatar

    I think the kata description should be updated to say no regex. I originally wrote a solution using String.prototype.replace (which isn't an Object or Array prototype method) only to find on submission that replace isn't allowed.

    I enjoyed this kata, otherwise.

  • Custom User Avatar

    This isn't an issue with the kata. Run through what your code does using console.log(arr) at the end of each iteration and you should see why it doesn't pass the second test.

  • Loading more items...