import java.util.*; public class SmallestInFront { public static void main (String[] argv) { int[] testData = makeRandomArray (10); System.out.println ("Before: " + Arrays.toString(testData)); smallestInFront (testData); System.out.println ("After: " + Arrays.toString(testData)); } static void smallestInFront (int[] A) { // Start by assuming first is smallest. int smallest = A[0]; // We're going to record the position where the smallest occurs. int pos = 0; // Check against A[1], A[2] ... etc. for (int i=1; i