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 comment is hidden because it contains spoiler information about the solution
OP solved it, closing
Which tests? Please state the input values. Which language?
3 of textcases are giving incorrect results
The
return
line of this function will call the function itself as needed until a condition is met. This is known as recursion. Here's an alternate source.The error message reveals that your code is trying to access an element at an index not within range of the indices for this object. This most likely occurs at
arr[i+1]
.You passed the kata.
This comment is hidden because it contains spoiler information about the solution
Not a kata suggestion, please don't post solutions in Discourse.