@strong-roots-capital/sorted-cartesian-product
v1.0.0
Published
Cartesian product of a list including only sorted elements
Downloads
3
Readme
sorted-cartesian-product
Cartesian product of a list including only sorted elements
Install
npm install @strong-roots-capital/sorted-cartesian-product
Use
import { sortedCartesianProduct } from '@strong-roots-capital/sorted-cartesian-product'
let array = [1, 2, 3]
sortedCartesianProduct(array))
//=> [[ 1, 2 ], [ 1, 3 ], [ 2, 3 ]]