let arr = [[1, 2], [3, 4]] let list = arr.map(([a, b]) => a + b); console.log(arr) console.log(list) function move({x = 0, y = 0}) { console.log([x,y]) return [x, y]; } move({x: 3, y: 8} ); // [3, 8] move({x: 3}); // [3, 0] move({}); // [0, 0] //move(); // [0, 0]