/** * 经典排序法 * * @param $origin * @param array $accounts * @return array */ public static function sort($origin, array $accounts) { $sorter = new Sort($origin, $accounts); $results = $sorter->all(); return self::revertData($results, $accounts); }
public static function sort($origin, array $accounts) { $sorter = new Sort($origin, $accounts); $results = $sorter->all(); return $results; // return implode(', ', $results); // // usort($matches, function ($a, $b) use ($word) { // return similar_text($word,$a) - similar_text($word, $b); // }); }