const rillet = require('./rillet.js');
const { of, zip, numbers } = rillet;
const fizzes = () => of('', '', 'Fizz').cycle();
const buzzes = () => of('', '', '', '', 'Buzz').cycle();
const words = () => zip(fizzes(), buzzes()).map(([f,b]) => `${f}${b}`)
const integers = () => numbers(1);
const fizzbuzz = (howMany) =>
zip(words(), integers()).
map(([w, n]) => w ? w : n).
take(howMany);
fizzbuzz(100).forEach(console.log);
