variations-stream

    0.1.3 • Public • Published

    variations-stream

    A readable stream that generates all the variations (with repetitions) of a set.

    NPM version Build Status Downloads

    Install

    Node.js

    npm install variations-stream
    

    Usage

    var variationsStream = require('variations-stream');
     
    variationsStream('abc', 2)
      .on('data', function(comb) {
        console.log(comb);
      });
     
    /* Prints:
     
    a
    b
    c
    aa
    ba
    ca
    ab
    bb
    cb
    ac
    bc
    cc
     
    */
     

    Credits

    Install

    npm i variations-stream

    DownloadsWeekly Downloads

    153

    Version

    0.1.3

    License

    none

    Last publish

    Collaborators

    • avatar