Using 2 classes and the main class will be MidtermP2Demo Develop a Java program that lets the user input the elements of an array of ints which has 10 slots and output the following: sumAll(): Sum of...


Using 2 classes and the main class will be
MidtermP2Demo


Develop a Java program that lets the user input the elements of an array of ints which has 10 slots and output the following:



sumAll():
Sum of the elements in the array


averageAll():
Average of the elements in the array


max():
Highest value in the array


min():
Lowest value in the array


gcd():
Greatest common divisor of the elements


lcd():
Least common denominator of the elements


sumEven():
Sum of all even numbers/elements


sumOdd():
Sum of all odd numbers/elements


sumSqrt():
Sum of the square roots of the elements


sumPrimes(): Sum of all prime numbers/elements


Classes: MidtermP2,
MidtermP2Demo


Develop a Java program that lets the user input the elements of an array of ints which has 10 slots and output the following:<br>• sumAll(): Sum of the elements in the array<br>• averageAll(): Average of the elements in the array<br>• max(): Highest value in the array<br>• min(): Lowest value in the array<br>• gcd(0: Greatest common divisor of the elements<br>• Icd(): Least common denominator of the elements<br>• sumEven(): Sum of all even numbers/elements<br>• sumodd(): Sum of all odd numbers/elements<br>• sumSqrt(): Sum of the square roots of the elements<br>• sumPrimes(): Sum of all prime numbers/elements<br>Classes: MidtermP2, MidtermP2Demo<br>

Extracted text: Develop a Java program that lets the user input the elements of an array of ints which has 10 slots and output the following: • sumAll(): Sum of the elements in the array • averageAll(): Average of the elements in the array • max(): Highest value in the array • min(): Lowest value in the array • gcd(0: Greatest common divisor of the elements • Icd(): Least common denominator of the elements • sumEven(): Sum of all even numbers/elements • sumodd(): Sum of all odd numbers/elements • sumSqrt(): Sum of the square roots of the elements • sumPrimes(): Sum of all prime numbers/elements Classes: MidtermP2, MidtermP2Demo

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here