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.
The example inputs all show Ranges, but you've specified that the input argument should be an array. Change this, and perhaps provide an example of a non-Range input.
Also, you may want to change the wording on the correct output format to emphasize that you want the values in sorted ascending order, rather than in the same relative ordering of the input array.
Well shoot. I definitely went for the easy Hash solution. Kudos for not letting the Hash take the place of an actual algorithm
Like a lot of the regex based solutions at the top, but mine performs just 2 passes (one for each op level) through the string, rather than restarting the regex from the beginning on every single reduction step.
Given how weak the type system is, it's almost always safer to use the stricter === check. If the sorting fails, that's a good indication that you need to examine your input to determine why you're trying to sort an array of mixed strings and ints.
Good point, that's correct.