maybe just use `uasort($keys, 'strlen'); $keys = reverse($keys)` to avoid the extra sorting method