I found this code snippet on codeforces.
public static int[] sort(int[] a) {
a = shuffle(a, new SplittableRandom());
Arrays.sort(a);
return a;
}
Is this a better way to sort an array rather than using just Arrays.sort(a)
. Why or Why not?