3 lines
106 B
JavaScript
3 lines
106 B
JavaScript
const xProd = (a, b) => a.reduce((acc, x) => acc.concat(b.map(y => [x, y])), []);
|
|
module.exports = xProd;
|