Files
30-seconds-of-code/test/xProd/xProd.js
Angelos Chalaris 79a70885ad Tests for averageBy, maxBy, minBy
Fixed examples in minBy
2018-01-24 17:38:08 +02:00

2 lines
104 B
JavaScript

const xProd = (a, b) => a.reduce((acc, x) => acc.concat(b.map(y => [x, y])), []);
module.exports = xProd