Ad

Given an array of numbers, return the total value of all the numbers.

function addArr(arr){
  
  if(arr.length === 0) return null
  
  let final = 0
  arr.forEach(num => {
    final += num
  })
  return final
}