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.
Help us help you. Tell us what language you're having these problems with.
The JavaScript translation meanwhile has been fixed to allow for floating point inaccuracy.
Closing.
Print the input.
Your code is sorting the strings in ascending order of length, and then joining k of them from the back, that's wrong. Your code should obtain the longest string made of k consecutive strings from the array that is the longest (and if there is more than one with the longest length, then your code should return the first one).
Why are you sorting? The strings must be consecutive.