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 solution is not working now
You overwrite
$return
on every single line, so they could all be false except for the last call and it would return true. Right?Yes! but the conversion is easy and short, so... why not? xD Regards!
array_count_values() was my first pick, too, but then I realized, that PHP only allows strings or integers as array keys. That's why this weird string conversion has to happen.
Mmm, put this in a line -> $n = str_split(strval($n));rsort($n);
Just for make fewer lines of code, is bad practice...