0

this code finds the max element in an array using the reduce command.

function getMaxY(){
    return data.reduce((max, b) => Math.max(max, b.y), data[0].y);
}
Buttslaya
  • 1
  • 1

0 Answers0