Ad
  • Custom User Avatar

    If the idea is to make sure we check for invalid input, you could be a lot more evil and include fixed texts for 02/30/YEAR, 09/31/YEAR, or even 02/29/2001 if you're feeling particularly devilish. Most solutions I have seen so far would have failed those.

    Right now the test cases are in an odd in-between zone: they are enough to annoy the warriors slightly and stop us from finishing the kata on autopilot, but they do not truly put our answers to the test.

  • Custom User Avatar

    Nice kata. The test cases are not good enough though. My solution produced the output 1806 (expected 1807) for input age("10/09/2104","10/09/3911"), but I could still push it through in the next submission. Also, it would be good to mention what needs to be done about leap years.

  • Default User Avatar

    Might explicitly put in the description that rounding down is necessary.

  • Custom User Avatar

    You're right indeed. It reminds me that getMonth and getMonth() is definitely not the same thing. I made this test an example test case as well. Thanks.

  • Custom User Avatar

    Sorry about that, the right format is definitely 'mm/dd/yyyy'. Thx

  • Default User Avatar

    Mistake in one of the tests:
    Error : birthday= 06/09/3051 and enddate= 04/23/4208 -> result should be 1157 and not 1156

  • Default User Avatar

    Description says: The entries must have this format : "mm/dd/yyyy" and one of the tests says: Should return -1, One of your date doesn't have the good format 'DD/MM/YYYY'

  • Custom User Avatar

    Thanks for the comment. I made more precise error messages. Hope it'll help

  • Custom User Avatar

    you're right. I added random test cases and corrected the examples.

  • Custom User Avatar

    thanks for commenting. I added random test cases and corrected the examples

  • Custom User Avatar

    Tests aren't descriptive and hard to debug.

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    1.your example testcase 3 and 4 have a wrong answer.
    2.need some random testcase.