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.
It's a little tip, but it helped me a lot!
Not an issue.
Are you sorting the array? The sort method mutates the array in place (console.log doesn't, don't worry).
Your answer is right, and mutating the array has the side effect of the tests looking for wrong answer.
probably you use
pop
or somehting like that on the list further in your code. That's where you're mutating the input.Hint: Do not modify the original array.
no, its suppose to be 63, its the largest consecutive sum. in this case, 63 was calculated from 2+43+-5+23
for yours (43+23), you would also need to include the -5, which results to: 43+-5+23