1void shuffle(int [] arr) {
2 for (int i = 0; i < arr.length; i++) {
3 int index = (int) (Math.random() * arr.length);
4 int temp = arr[i];
5 arr[i] = arr[index];
6 arr[index] = temp;
7 }
8 }
1for (int i = myList.length - 1; i > 0; i--){
2 int j = (int) (Math.random() * (i + 1));
3
4 double temp = myList[i];
5 myList[i] = myList[j];
6 myList[j] = temp;
7 }