Ad
  • Custom User Avatar

    I code on PHP, i just don't understanding why it fails in logic section, it doesn't even saying why it fails it just saying "Invalid input" so i don't even getting where it fails, when i run every unit test in my ide everything work fine but when i attempt it fails for some reason, so plz take a look.

  • Default User Avatar

    The problem is poorly written, it needs the grammar checked so that it can be read easily.

  • 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

  • Default 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

  • Default User Avatar
  • Custom User Avatar
    • Rounding problems are ofc present... depending on how the conversions are handled, users might end up with a correct solution that doesn't pass
    • the exact formatting expected for float sizes isn't specified (and is rather dubious): flooring, but trailing 0 removed
    • sample tests are almost useless: missing the example from the description + something involving floating points + conversion leading to ddd0 unit, ddd.d unit
  • Custom User Avatar

    like @slawaa said, my code resulted in some variations that diverged by 1.
    Multiple attempts were made before I get to pass the test, despite the same code.

  • Default User Avatar

    From the description it is unclear where to ceil in the calculation process. Because of that my solution did run randomly into errors because the results diverged by 1 here and there. It passed after I got "lucky" on an attempt iteration.

  • Custom User Avatar

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

  • Custom User Avatar

    Expected: [135, 101, 128], instead got: [135, 102, 128]

    Expected: [132, 86, 174], instead got: [132, 87, 174]

    2 errors, but i calculated on the calculator and displayed my values

  • Default User Avatar

    At least in Ruby: solutions that use character codes instead letter indices pass the tests.
    https://www.codewars.com/kata/reviews/59582f6dd1773f3dcb00013e/groups/595967d5b7a2173ff6000543

  • Custom User Avatar

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

  • Default User Avatar

    Hello!

    Kata "task" has no mention of sorting keys:

    If automaton receives an object it will return an array of 3 elements: [n, keys, values] where n is the number of keys, keys is an array of all keys, and values is an array of stringified values. Examples:

    all keys for array with length == 12 is:

    arr = new Array(12).fill('');
    Object.keys(arr);
    // -> ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11"]
    

    but if you sort keys array - this will happen:

    arr = new Array(12).fill('');
    Object.keys(arr).sort();
    // -> ["0", "1", "10", "11", "2", "3", "4", "5", "6", "7", "8", "9"]
    

    So, i want to suggest to (1) add a sorting requirements to the description, or (2) fix the tests (something like: sort((a, b) => a < b ? 1 : (a > b ? -1 : 0)) can help (maybe?)).

  • Loading more items...