1.0.0 • Published 4 years ago

@sithikus/numbers v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

@sithikus/numbers

Number utilities used within @sithikus packages.

NPM Version

Install

npm i @sithikus/numbers

Usage

getUniqueCombinations

Returns all combinations of length, summing to sum.

import '@sithikus/numbers';

var uniqueCombinations = [1, 2, 3, 4, 5].getUniqueCombinations(5, 2); 
//uniqueCombinations == [[2,3], [1,4]]

getPermutations

Returns all permutations of the array's contents.

import '@sithikus/numbers';

var permutations = [1, 2].getPermutations(); 
//permutations == [[1,2], [2,1]]

License

This project is licensed under the terms of the MIT license.

1.0.0

4 years ago

0.3.1

4 years ago

0.3.0

4 years ago

0.2.6

4 years ago

0.2.3

4 years ago

0.2.5

4 years ago

0.2.4

4 years ago

0.2.2

4 years ago

0.2.1

4 years ago

0.2.0

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago