Consider the following Java program. It has a number of methods with
empty implementations. Your task is to complete the methods so that
they perform the functions described by their names. For example,
the method getAverage(int[] a)
must calculate the average of the elements of the array a.
The program also calls the method printArray(int[] a).
After completing the method bodies write statements to call those
methods on your array.
public class ArrayMethods {
public static void main (String [] args) {
ArrayMethods arrayMethods = new ArrayMethods();
int[] a = arrayMethods.createArray();
arrayMethods.printArray(a);
}
public /* What type goes here? */ createArray() {
}
public void printArray(int[] a) {
}
public int getSum(int[] a) {
}
public double getAverage(int[] a) {
}
public int getMax(int[] a) {
}
}