Created
August 1, 2017 14:27
-
-
Save hunterloftis/a11c51c7216a891553505ec114300bec to your computer and use it in GitHub Desktop.
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
for (let i = 1; i <= 100; i++) { | |
const match = [] | |
if (i % 3 === 0) match.push('fizz') | |
if (i % 5 === 0) match.push('buzz') | |
if (match.length === 0) match.push(i) | |
console.log(match.join('')) | |
} |
Author
hunterloftis
commented
Aug 1, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment