public static String[] unique(String[] arrays) {
        List<String> list = new ArrayList<>(arrays.length);
        for (String arr : arrays) {
            if (!list.contains(arr)) {
                list.add(arr);
            }
        }
        String[] res = new String[list.size()];
        int i = 0;
        for (String arr : list) {
            res[i++] = arr;
        }
        return res;
    }
public static String [ ] unique ( String [ ] arrays ) { List < String > list = new ArrayList < > ( arrays . length ) ; for ( String arr : arrays ) { if ( ! list . contains ( arr ) ) { list . add ( arr ) ; } } String [ ] res = new String [ list . size ( ) ] ; int i = 0 ; for ( String arr : list ) { res [ i ++ ] = arr ; } return res ; }
去重

@param arrays 数组

@return 去重后的数组