Created
April 7, 2021 08:28
-
-
Save vlad-ds/120f1e55c923e2f23c978756bd67ad8c to your computer and use it in GitHub Desktop.
A Cooler Fizzbuzz
This file contains hidden or 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
def fizzbuzz(n): | |
return [('' + 'Fizz' * (not x % 3) + 'Buzz' * (not x % 5)) or x for x in range(1, n+1)] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment