Question: Create a Class called MyMathClass The class handles bound type parameters that extend the API Number class. See Bound for Type Parameters(around pg 793 in

Create a Class called MyMathClass

The class handles bound type parameters that extend the API Number class. See Bound for Type Parameters(around pg 793 in text)

average method

takes in a type parameter ArrayList

returns a double representing the average of the ArrayList elements

standardDeviation method

that takes in a type parameter ArrayList

returns a double representing the Standard Deviation of the ArrayList elements.

Standard Deviation Equation

Sqrt of the sum of the difference between each element in the array and the average of all elements in the array.

Standard Deviation = Sqrt( (Sum_i=1_to_N(element i - average)) / N) where N is the number of elements in the array.

Create a Class classed MyMathClassTester

Creates three ArrayLists, one for each type of numeric Object Type(Integer, Double and Long)(you must use an L fpr any number literal to a Long before passing it to the List)(example 2348575758390L)

Add at least three appropriate number to each ArrayList

Create a MyMathClass object for each type (Integer, Double and Long)

Call the Standard Deviation method for each MyMathClass object and display the results.

What happens if you create a MyMathClass object with a String type parameter?

Add the answer to the above question as comments at the bottom of your MyMathClassTester

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!