function getAverageTestScore(scores) {
var total = 0;
for (var i = 0; i < scores.length; i++) {
total += scores[i];
}
const avg = total / scores.length;
// const avg = scores.reduce((a, b) => a+b )/ scores.length;
return avg
}
let avg = getAverageTestScore([80, 100]);
console.log(avg, '<-- should be 90');