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.
This problem is NP-Hard, so it's unlikely it can be made any more efficient.
Never assume your code not working is an issue. An issue is a bug in the kata and it needs to be proved. I strongly advice you to read carefully the official recommendation page: https://docs.codewars.com/training/troubleshooting/
It is a little confusing. Regarding the example, this may help a bit. I don't think it's a spoiler.
maxSequence([-2, 1, -3, (4, -1, 2, 1,) -5, 4])
Read the comment by 'NHerwich' from about 8ish months ago(prior to my comment). That person explains the basics, the kata description talks about if all numbers are negative or if the array is empty. One other maybe helpful clarification is that a single(positive) number in an array can be the answer if it happens to be the only number, only number > 0, or if no other amount of numbers added together is greater than it.
The real miles number can contain 4. Let's see 55: it skips 4, 14, 24, 34, 40 and 54, so 55 - 15 = 40.