Neanderthal Painting Monet
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    pair-me-uppublic

    pair-me-up

    Gives a range, each paired with one another

    NPM

    Usage

    var pair = require('pair-me-up');
    var pairs = pair(1, 30);
     
    console.log(pairs);
    // [[1, 5], [2, 17], [3, 2], [4, 10], ...] 

    You can also shuffle the resulting pairs:

    var pair = require('pair-me-up');
    var pairs = pair(1, 5, true);
     
    console.log(pairs);
    // [[3, 2], [5, 1], [2, 5], [4, 2], ...] 

    view on requirebin

    Keywords

    none

    install

    npm i pair-me-up

    Downloadslast 7 days

    1

    version

    0.1.0

    license

    ISC

    repository

    github.com

    last publish

    collaborators

    • avatar