Ad
  • Custom User Avatar

    it's unclear whether strings consisting entirely of spaces are possible input or not. the description does say that the string can be empty, and several languages have a fixed test with an empty string that results in an empty array, which is probably the intended answer for a string consisting entirely of spaces as well.

  • Custom User Avatar

    Nice kata, but it would be great to have a preloaded "events" dictionary that maps snakes and ladders where keys represent the old positions and values the new ones.

    This would save time and effort and help prevent mistakes from transfering the values by hand.

  • Custom User Avatar

    Couldn't it be better to show why the tests aren't passing?

    like saying the moves played so far so that I track where the problem in code is

    my code passed 1000 tests and didn't pass another 1000 ones

  • Custom User Avatar

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

  • Custom User Avatar

    Should maybe specify in description whether or not, when a fish is eaten, any "leftovers" from that fish not needed to attain the next level can contribute to getting the next level, or if the whole fish is lost in growing to the next level so that only the next fish can begin contributions to the next level. It appears that the former is true.

  • Custom User Avatar

    two boundary case are problematic:

    • when the interval is exactly enough to compensate for the alcohol units drank, the expected answer is false, which is surprising and should be mentioned in the description; there is even a sample test drive([[10.0,100]], "20:00", "21:00") that expects [1.0, false], so it does not seem like an oversight

    • If the finished >= drive_time then you can assume that it is the next day.

      yet the reference solutions uses >, not >=, so cases like this show up in the random tests:

      last_drink_time = "23:21" ; departure_time = "23:21"
      [8.33, True] should equal [8.33, False]
      
  • Custom User Avatar

    all languages: typos in the parameter names (vilian -> vilain, vilians -> vilains)

  • Custom User Avatar

    Python:

    • test and scoobydoo should be imported explicitely
    • shift() should not be in the preloaded module
  • Custom User Avatar

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

  • Custom User Avatar

    the paramter reels should be const char *const[] in C, as the user is not supposed to mutate it

  • Custom User Avatar

    Nice problem, but it's hard to debug, because printing out the input fulls the buffer because the random tests are so long.

    It would help to either display the input on the first failing random test, or add two more cases to the sample tests:
    A case where the initial position is not on the top floor.
    A case where the initial position is on the bottom floor, but there's more than one floor.

  • Custom User Avatar

    Java:

    • Missing fixed tests

    • should be updated to JUnit5 (in the meantime)

  • Custom User Avatar

    Can anyone explain me:How we get for "111111111111111111112222222222" the length of the fish is 5?
    I've found it
    1111 (2) 2222 (3) 111111111111 (4) 1111222222 (5)

  • Custom User Avatar

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

  • Custom User Avatar

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

  • Loading more items...