Skip to content

Latest commit

 

History

History
9 lines (8 loc) · 297 Bytes

array-function-average.md

File metadata and controls

9 lines (8 loc) · 297 Bytes

Given an array of three numbers , create a function average that accepts the array as a parameter and returns the average of the three numbers in the Array.

function average(numberArray){
// write your code here
}
let numbers = [1,2,3];
console.log(average(numbers)); // SHOULD PRINT 2