My solution is correct, but I thought I would need to include one more step where I use .push() to send the largest number from each subarray into it’s own array. Why isn’t .push() required in this case? I think it’s because of my use of .map(), but wanted to double check to make sure.
function largestOfFour(arr) {
let largest = arr.map( (a) => {
a.reduce( (x,y) => {
return largest = x > y ? x : y;
});
return largest;
});
return largest;
}