Arrays.sort(array); for (int i = 0;i<array.length;i++) { array[i] = array[array.length - i - 1]; }