collatz-series
v1.0.1
Published
calculates a collatz series of integers given a positive integer
Downloads
11
Readme
collatz-series
Calculates the Collatz series given a positive integer.
api
const collatz = require('collatz-series')
console.log(collatz(44))
// [ 44, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1 ]