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.
yes
in according with indexOf docs
"The indexOf() method returns the first index at which a given element can be found in the array, or -1 if it is not present."
it can be found on this mdn link
This means whatever is not in geese, the return value would be negative?
I really like the readability of this solution. Although the double map iteration is inefficient it's probably worth it for the readability.
This feels like an 8 kyu to me. It's too straight forward for 7 kyu.
Nice use of
group_by
to improve efficiency. Always try sorting before you count, good job.I'm thinking it would be more memory efficient in the case of very large numbers.