Question: In JavaScript , create a function called MinMaxSum which holds an array of integers and report the sum of the lowest and the highest values

In JavaScript, create a function called MinMaxSum which holds an array of integers and report the sum of the lowest and the highest values in the array.

The output is the sum of the max and min values.

Example of the code:

function MinMaxSum (MyArray) {

// Insert code here;

}

MinMaxSum ([1,2,3,7]);

Output: 8

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!