Ad
  • Default User Avatar

    @Bliuss

    You will not always get the highest sum by always picking the highest of two values.

    Can you please explain why? Is there is more than two ways available in each line of the pyramid? If its not, then why adding a bigger number dont get you bigger sum in the end?

    Edit: oh, i got it, sorry.

  • Default User Avatar

    You should try this data: [[1], [2, 1], [1, 2, 3, 99]] ,and you will find where is wrong.

  • Default User Avatar

    This is a work of art. Beautiful.

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

  • Default User Avatar

    I know absolutely nothing about nodes, yet I don't understand why this is 3 kyu. Nothing special, at least in Java.

  • Default User Avatar

    I don't understand why this is 4 kyu. Are the test cases so simplistic that I am actually doing something I shouldn't?

  • Default User Avatar

    I misunderstood both the problem and the approach that should be used.

  • Default User Avatar

    Same. I have done this 5 or 6 times now and it always gives me 1064. This makes me so upset cause I hate skipping problems.

    Am I missing something here @whythat?

  • Default User Avatar

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

  • Default User Avatar

    I admit I was wrong, although I find strange the amount of people, including myself, who think the problem had to be solved with square root. I was also reading the expected value wrong in test 3.

    However it's kind of almost everywhere in the description where you talk about squaring...

  • Default User Avatar

    Where did you see that the focus is about square root? or about squaring ? The question is to see if the two arrays are "the same" and it is up to you to find a code for that.

  • Default User Avatar

    You can multiply a negative value with itself and it will give the same result as if you multiplied with positive values, but if you square root the result it's mathematically impossible to get a negative result.

    So yeah, you can make it pass if instead of square rooting the "b" list you square the "a" list instead, which is incorrect if the focus of the problem is square root and not the opposite.

  • Default User Avatar

    Tests are the same in all languages and 7919 guys passed the kata. Something is wrong in your code:-(

  • Default User Avatar

    On Java tests, test 3 expects true when array "a" is empty and on test 8 the second value on array "a" is a negative and expects true, you can't get negative values from square root.