Menu

[Solved]Create Application Containing Array Stores Eight Integers Application Call Five Methods Tu Q37182032

Create an application containing an array that stores eightintegers. The application should call five methods that inturn:

  1. Display all the integers
  2. Display all the integers in reverse order
  3. Display the sum of the integers
  4. Display all values less than a limiting argument
  5. Display all values that are higher than the calculated averagevalue.

public class ArrayMethodDemo {
public static void main (String args[]) {
int[] numbers = {12, 15, 34, 67, 4, 9, 10, 7};
int limit = 12;
display(numbers);
displayReverse(numbers);
displaySum(numbers);
displayLessThan(numbers, limit);
displayHigherThanAverage(numbers);
}
public static void display(int[] numbers) {
// Write your code here
}
public static void displayReverse(int[] numbers) {
// Write your code here
}
public static void displaySum(int[] numbers) {
// Write your code here
}
public static void displayLessThan(int[] numbers, int limit){
// Write your code here

}
public static void displayHigherThanAverage(int[] numbers) {
// Write your code here
}
}

Expert Answer


Answer to Create an application containing an array that stores eight integers. The application should call five methods that in t… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *