Question: 6. Write a JavaScript function that takes mylist and y as its inputs where mylist is an array of numbers and y is a number.
6. Write a JavaScript function that takes mylist and y as its inputs where mylist is an array of numbers and y is a number. If the average of all numbers in mylist is less than y, the function returns true and it returns false otherwise. For example, if mylist=[3,5,8,4 and y=10, then the average of numbers in mylist is 5 which is less than y (y is equal to 5). In this case, your function must return false (3pt)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
