Created
September 6, 2017 04:28
-
-
Save courtneyfaulkner/178da46673562b16eb5222b0d7250dca to your computer and use it in GitHub Desktop.
[FizzBuzz] #practice
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
class FizzBuzz { | |
static void main(String[] args) { | |
(1..100).each {println((it % 3 ? '' : 'fizz') + (it % 5 ? '' : 'buzz') ?: it)} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment