public static function each(string $str, callable $callable, string $encoding = null, ...$args) : string
    {
        if ($str === '') {
            return $str;
        }

        $result   = '';
        $encoding = $encoding ?: utils\Str::encoding($str);
        $length   = mb_strlen($str, $encoding);

        for ($idx = 0; $idx < $length; $idx++) {
            $result .= (string) call_user_func($callable, mb_substr($str, $idx, 1, $encoding), $idx, ...$args);
        }

        return $result;
    }