I'm trying to return all array numbers as negative numbers (* -1); I'm stuck. Please help!
function makeListNegative (array){
for(i=0; i <array.length; i++);
return i * -1;
}
var negativeList = makeListNegative([7, 2, 3, 4]);
console.log(negativeList);
This function only returns that last number in the array as -4. I would like ALL list numbers to be displayed.