Swaps the elements at the given indices in the array. @param a - the index of one element to be swapped. @param b - the index of the other element to be swapped. @param arr - the array in which to swap elements.
(int a, int b, Object[] arr)
| 2381 | * the array in which to swap elements. |
| 2382 | */ |
| 2383 | private static void swap(int a, int b, Object[] arr) { |
| 2384 | Object tmp = arr[a]; |
| 2385 | arr[a] = arr[b]; |
| 2386 | arr[b] = tmp; |
| 2387 | } |
| 2388 | |
| 2389 | /** |
| 2390 | * Performs a sort on the section of the array between the given indices |