There is a way to write "pure functional" FizzBuzz, without accumulating or checking the condition twice, but should you? No. <!-- begin snippet: js hide: false console: true babel: false --> <!-- language: lang-js --> function fizzbuzz(n) { const test = (divisor, callout, f) => (n % divisor === 0) ? () => callout + f('') : f; const fizz = test.bind(this, 3, 'Fizz'); const buzz = test.bind(this, 5, 'Buzz'); return fizz(buzz(x => x))(n); } document.write(Array(100).fill().map((_,i) => fizzbuzz(i+1))); <!-- end snippet --> Based on https://youtu.be/dC9vdQkU-xI?t=25m9s