Last active
April 9, 2017 10:13
-
-
Save slikts/feace47cf123add0f6a5e5d1e3be8cc1 to your computer and use it in GitHub Desktop.
FizzBuzz oneliner
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fizzBuzz = (a, b) => Array.from(Array(b - a), (_, i) =>a + i).map(x => `${!(x % 5) ? 'Fizz' : ''}${!(x % 3) ? 'Buzz' : ''}` || x) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment