function repeat(times) {
    return function* (it) {
        const buffer = [];
        for (const item of it) {
            buffer.push(item);
            yield item;
        }
        for (let i = 0; i < times; ++i) {
            yield* buffer;
        }
    };
}
function repeat(times) {
    return function* (it) {
        const buffer = [];
        for (const item of it) {
            buffer.push(item);
            yield item;
        }
        for (let i = 0; i < times; ++i) {
            yield* buffer;
        }
    };
}
function repeat ( times ) { return function * ( it ) { const buffer = [ ] ; for ( const item of it ) { buffer . push ( item ) ; yield item ; } for ( let i = 0 ; i < times ; ++ i ) { yield * buffer ; } } ; }
Play the given Iterable, and then it N more times
Play the given Iterable and then it N more times