Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
@Bliuss
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.
You should try this data: [[1], [2, 1], [1, 2, 3, 99]] ,and you will find where is wrong.
This is a work of art. Beautiful.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
I know absolutely nothing about nodes, yet I don't understand why this is 3 kyu. Nothing special, at least in Java.
I don't understand why this is 4 kyu. Are the test cases so simplistic that I am actually doing something I shouldn't?
I misunderstood both the problem and the approach that should be used.
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?
This comment is hidden because it contains spoiler information about the solution
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...
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.
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.
Tests are the same in all languages and 7919 guys passed the kata. Something is wrong in your code:-(
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.