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
This comment is hidden because it contains spoiler information about the solution
Your code not working is not an issue (= a bug in the kata). Please read this: https://docs.codewars.com/training/troubleshooting/
This comment is hidden because it contains spoiler information about the solution
I guess it doesn't make an error when you access the arr[i+1] when i = arr.length-1. It shoud say try to access undefined.
Check this one as well;
https://www.codewars.com/kata/reviews/5bbb8890484fcd36fb0020cc/groups/5bbcf8a3b6dfbb59fc0028bb