class NumberOps { // Operations on an array of integers a, // dealing with the first n integers only. public static void printall(int [] a,int n) // Print the first n contents of array a { int i; for(i=0; icurrent) current=a[i]; return current; } public static int smallest(int [] a,int n) // find the smallest of the first n contents of array a { int i,current=a[0]; for(i=1; ia[pos]) pos=i; return pos; } public static int posSmallest(int [] a,int n) // find the position of the smallest of the first n contents of array a { int i,pos=0; for(i=1; i