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.
Fixed
Holy fuck the Python tests were written by a literal psychopath.
None of the other languages I looked at generate tests like that anyway so I'm gonna just remove them.
You may have sussed it out by now, but some of the random test strings actually have double whitespace, and some of the test case outputs don't represent the double whitespace difference clearly due to word wrap.
RE the Python version:
The exercise description explitly warns the user that inputs may have TRAILING whitespace.
It says nothing about the mid-string double whitespaces that occur during the random acceptance tests.
Combined with the word-wrap on the failed test strings, and the difficulty in visually parsing a random group of letters split by what you're assuming to be single whitespace characters, this results in the test case appearing to show for example "this string" should be "this string". But with a double whitespace invisible to the user due to being wrapped on to a new line. This can prove very challenging for a rookie to debug, especially with the limited ability to display script output within Codewars.
It's likely that a user will split a string using ' ' explitly to represent whitespace between words, and strip trailing space from their result, but not expect double whitespaces within the string itself.
I'd suggest updating the description to explitly state double whitespaces may be included, and/or add to the fixed test cases examples where the string has double whitespaces between words.