Ad
  • Default User Avatar

    Perhaps retrace your steps as to discern at which point you were mistaken in perceiving that the kata had some functional flaw. Take note that the JavaScript version of this kata has been solved over 1K times and please keep in mind that in order to post an issue on a kata, you should be able to explain how and why it occurs, and provide examples of test cases where the breakdown occurs, such as: input, expected output, your code result, and the like. Otherwise, you should post as a question instead. Nevertheless, given that you no longer perceive any flaw, you should mark this as resolved.

  • Default User Avatar

    In Javascript, the tests were not properly working when I pressed the test button. I made sure my function returned the correct value for every test, and still, the test button resulted in the Odd tests working correctly, and the Even tests failing, displaying an error like "isarr is not defined at (line char)" (and isarr is part of the tests).

    I viewed other's solutions, and copied and tested their solutions, and got the same exact error. Tried loading the page in another browser to no avail.

    Oddly enough, when I clicked the submit button, everything passed. Despite this, clicking test again gave the same error...

    I tried to replicate this to copy the exact error here but now it's working fine.

  • Custom User Avatar

    Yeah but just like in the movie, it would not help too much. Thousands of eggs were laid, hundreds of them already hatched, and Ripley still needed her flamethrower to deal with the rest.

    Let'just hope that nuking the place from orbit is not the only option :D

  • Default User Avatar

    If you haven't seen the movie Aliens, there's a well known scene that perfectly represents this Kata.

    In the scene, the Marines are exploring a space colony that's been taken over by the aliens. As everyone's entombed in some alien biological matter, there seems to be no survivors- except for one poor soul, cocooned but barely alive. Upon being woken up, she utters her last desparate words- "Please... Kill... Me." She knows her terrible fate. Her last moments alive are wishing to die, violently convulsing while an alien lifeform bursts forth from her sternum.

    The phrase "Kill... Me..." has become pop-culture shorthand for "I am an abomination to both man and god, a violation of the laws of nature and decency so severe that my only wish is an end to my dreadful existence."

    If (when?) Katas become self aware, this one will surely beg us for its death.

    To the mods here, whoever has the power, I implore you! Put this horrendous beast out of its misery! Spare mankind the disgusting misfortune of ever laying eyes on it again! For the love of all that is good in the world, please KILL THIS KATA!

  • Default User Avatar
  • Default User Avatar

    I really enjoyed this one! I love katas that make you think about how to approach a problem.

    Like others, my initial solution timed out, and it took a while to identify the approach that worked.

  • Default User Avatar

    Without spoiling anything, I can say that thinking through the larger timed-out test cases was what helped me identify where/how the brute force needed to be applied.

  • Default User Avatar

    (Javascript)

    The first time I solved this kata, there was a strange sample test that may be some sort of error.

    The test was for input "C". Output was ["ab", "cd", "ef", "g_"]

    I wrote a if statement that returned that output for input "C", and it passed.

    I went back to the kata just now so I could copy the sample test and list it here, but now the sample test isn't there. Not sure how this happened or how rare it is, but I figured it's worth mentioning.

    Otherwise, thanks for the fun kata.

  • Default User Avatar

    I think James needs to find another line of work.

  • Default User Avatar

    This was a very satisfying Kata.

    It took me a LONG time to complete, but for each problem I had with my initial solution, a logical fix emerged.

    Challenging without any funky edge cases, thanks.

  • Default User Avatar

    Nice Kata, challenging but satisfying, without any pesky edge cases. Thanks!

  • Default User Avatar

    As someone whose last math class was before 9/11, I sometimes feel this way, but not this time!

    This was clearly explained, with great examples.

    Plus, it was an actual coding challenge, not some Math-trick riddle that's useless in real life.

  • Default User Avatar

    The description of this Kata remains unclear.

    The description asks for a function with three stipulations:

    1: the function "returns the sum of a sequence".
    2: the sequence "is defined by 3 non-negative values".
    3: the function "should returns 0" ... "If begin value is greater than the end".

    According to this, in the case of rule 3, the sequence is still valid, and summing it 'should return 0'.

    The description could be clearer by asking for a function that "returns the sum of a sequence if begin value is less than end, otherwise returning 0."

    Not sure if this contributed to any confusion among the commenters, but I spent time trying to modify my function so that it would still return the sum of the sequence for all tests. Certainly beyond the difficulty of a 7kyu, but should anyone else interpret it literally, hopefully this will save you time.

  • Default User Avatar

    Gotcha. Thanks again for the quick reply.

    Looks like I'll be revisiting this kata again this weekend.

  • Custom User Avatar

    Probably when those solutions passed the tests, the tests were more lenient. Automatic revalidationg doesn't trigger for katas with many solutions, so it has to be done manually.

  • Loading more items...