Using require will throw an error if conditions are not met. Kata says "should detect when..." not "should throw error when...". So the kata doesn't want you to throw an error. It wants you to only do stuff when conditions are met, and do nothing when they are not.
Using require will throw an error if conditions are not met. Kata says "should detect when..." not "should throw error when...". So the kata doesn't want you to throw an error. It wants you to only do stuff when conditions are met, and do nothing when they are not.
wow I didn't know there this is function, well done!
Using require would be better in this situation. So your code is "correct" but the kata's tests are wanting you to do something else.
Using require will throw an error if conditions are not met. Kata says "should detect when..." not "should throw error when...". So the kata doesn't want you to throw an error. It wants you to only do stuff when conditions are met, and do nothing when they are not.
Using require will throw an error if conditions are not met. Kata says "should detect when..." not "should throw error when...". So the kata doesn't want you to throw an error. It wants you to only do stuff when conditions are met, and do nothing when they are not.
Not an issue, a question.
This comment is hidden because it contains spoiler information about the solution
Second test fails. I think instead of "history", actual value should be "lost" judging based on first test.
Why not returning end_a > end_b? The experession evaluates to boolean :)
This comment is hidden because it contains spoiler information about the solution