@CodeReview(reviewer="Kevin R. Dixon",date="2008-10-02",changesNeeded=false,comments="Looks fine.") @CodeReview(reviewer="Kevin R. Dixon",date="2006-07-18",changesNeeded=false,comments={"Added a couple comments.","Otherwise, looks fine."}) public class ArrayIndexSorter extends java.lang.Object
Constructor and Description |
---|
ArrayIndexSorter() |
Modifier and Type | Method and Description |
---|---|
static int[] |
sortArrayAscending(double[] valuesToSort)
Returns the indices of the array sorted in ascending order
|
static int[] |
sortArrayDescending(double[] valuesToSort)
Returns the indices of the array sorted in ascending order.
|
public static int[] sortArrayAscending(double[] valuesToSort)
valuesToSort
- values that should be sorted in ascending order,
via a call to Arrays.sort(), does not change values of "valuesToSort"public static int[] sortArrayDescending(double[] valuesToSort)
valuesToSort
- values that should be sorted in descending order