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
Description:
\t
is a whitespace character. Therefore, it should also be removed when it's in the end of the line. The line here is the result of removing the comment. This has also been demonstrated in the kata description. The space afterapples, pears
is removed, even though there's a comment after it.Not a kata issue.
Log
String: '\t. !\navocados avocados = strawberries #\npears watermelons'
Markers: ['!', '#', '@', "'", ',', '.', '^']
'\t\navocados avocados = strawberries\npears watermelons'
should equal
'\navocados avocados = strawberries\npears watermelons'
This asseration is incorrect. The marker . in the input string clearly comes after the \t character and therefore \t should be included in the output string.
Edit: removing \t's right before a marker fixed it even though that doesn't make sense
This comment is hidden because it contains spoiler information about the solution
This code crashed my code editor for large n.
Appending to a list, then summing, requires all entries to be saved in memory.
This causes a memory overflow crash for very large n.