Negligent Pachinko Machine

    step-generator

    1.0.3 • Public • Published

    step-generator

    Generate a sequence of numbers

    Build Status

    Installation

    $> npm install --save step-generator
    

    Test

    $> npm test
    

    Usage

    Generate a sequence of stepping numbers.

    const stepGenerator = require('step-generator')
    
    const evenGenerator = stepGenerator({ start: 2, step: 2 })
    
    const evens = [
        evenGenerator.next().value,
        evenGenerator.next().value,
        evenGenerator.next().value,
        evenGenerator.next().value,
    ]
    
    console.log(evens)
    

    Output

    [2, 4, 6, 8]

    Keywords

    none

    Install

    npm i step-generator

    DownloadsWeekly Downloads

    3

    Version

    1.0.3

    License

    MIT

    Last publish

    Collaborators

    • dustykeyboard