src/Pinyin.php
public function abbr($string, $delimiter = '', $option = PINYIN_DEFAULT)
    {
        if (\is_int($delimiter)) {
            list($option, $delimiter) = array($delimiter, '');
        }

        return implode($delimiter, array_map(function ($pinyin) {
            return \is_numeric($pinyin) ? $pinyin : mb_substr($pinyin, 0, 1);
        }, $this->convert($string, $option)));
    }
public function abbr($string, $delimiter = '', $option = PINYIN_DEFAULT)
    {
        if (\is_int($delimiter)) {
            list($option, $delimiter) = array($delimiter, '');
        }

        return implode($delimiter, array_map(function ($pinyin) {
            return \is_numeric($pinyin) ? $pinyin : mb_substr($pinyin, 0, 1);
        }, $this->convert($string, $option)));
    }
public function abbr ( $ string , $ delimiter = '' , $ option = PINYIN_DEFAULT ) { if ( \ is_int ( $ delimiter ) ) { list ( $ option , $ delimiter ) = array ( $ delimiter , '' ) ; } return implode ( $ delimiter , array_map ( function ( $ pinyin ) { return \ is_numeric ( $ pinyin ) ? $ pinyin : mb_substr ( $ pinyin , 0 , 1 ) ; } , $ this -> convert ( $ string , $ option ) ) ) ; }
Return first letters.

@param string $string
@param string $delimiter
@param int    $option

@return string
Return first letters .