Ad
  • Default User Avatar

    At least it's the program and not like most other solutions where people just tried to deceive the weak unit tests

  • Custom User Avatar

    I will not be able to say more precisely.If you will realise it right, you would find solution not so hard. But without seeing your option I can't be more specific. May be only "try to use step debuging" )

  • 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 task I solved at the fifth week of free courses. Lol, it was with bugs. Tests here made me to remove these bugs and learn how to use StringBuilder. At last. It's very convinient.
    Made recursive, not effective, but I wanted to practice it.
    Really, strong, but good kata.

  • Default User Avatar

    got 49 here, lol, but still failing random

  • Default User Avatar

    Tried these two cases, got 47 in first case and 50 in the second. But still failing randomtests

  • Default User Avatar

    Lol, now failing on random tests 39/15. Without looking Cadane's algorithm, wanna try beat it myself.
    Anyway, great kata. Respect to the author!

    [ 29, 46, 35, -33, 26, 26, -37, 15, 28, -48 ] here. got 129 from [ 29, 46, 35, -33, 26, 26,], expected 135.
    upd: found error. Not the only one, lol. It's fun.
    upd2: hurray! At least, it works. Had a lot of fun, really.

  • Default User Avatar

    You mean indexes?
    upd: oh, now i'm starting to understand, thanks

  • Custom User Avatar

    The positions in the array.

    maxSequence([-2, 1, -3, 4, -1, 2, 1, -5, 4])
                           |-----------|
    
  • Default User Avatar

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

  • Default User Avatar

    I think, no. Just look at the example. Average speed from [45.6, 74.4, 60.0, 60.0, 60.0, 60.0, 60.0, 60.0, 60.0] can't be 74.4

  • Default User Avatar

    If the input array is like this

    int[] integers = new int[] { -1721, 169, -32127, -81, 1014, -641, };

    Then some of the solutions in the list give an incorrect "outlier" and some of the solutions throw an exception.

  • Default User Avatar

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

  • Custom User Avatar

    I find it really bad that it is counting on a specific order of the functions to be called, trying to make the float error predictable or deterministic and then rounding it down.

  • Loading more items...