class Partition extends Object120 { /** Return an array where all "small" values are on the left, and "large" on the right. * * @param data The numbers to be partitioned. * @param threshhold the cut-off for what is considered "large". * @return an array like `data`, but first come all values < `threshhold`, * followed by the values >= `threshold`, in the same relative order * as in `data`. */ static void testPartition() { // After reading the below to get an idea of what assertEquals( new double[]{5,3,2,9,15}, partition( new double[]{9,5,3,15,2}, 7.0 ) ); } }