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.
When no value is passed to
reduce()
, like ([]
), where the initial value is 0. The reduce returns it's initial value.This comment is hidden because it contains spoiler information about the solution
this is just straight fire
Great idea!
Yeah you're totally right, it's very concise but not the most performant way. It could do with some kind of exit condition.
What if you got a very long string and it is not by the order in the second letter?
You will sort it anyway. I think it is not the best way
Nice! If you used join('') you wouldn't need the replaceAll.
Nice one!
Yes if you are going to use template literals, you need to use backticks!
Nice one! Great alternative to For loop.
Thank you! I was wondering how to do this. Didn't know you had to wrap the object in brackets.
It's because it's a test case that includes punctuation and spaces. Think this should be included in the description tbh.
Nice, more performant than my answer.
Definitely learned something from this Kata, thanks!
thank you.
Loading more items...