Skip to content

Instantly share code, notes, and snippets.

@fuwiak
Last active August 21, 2020 11:48
Show Gist options
  • Save fuwiak/6a79fb95d36aa73f19fe5357ff0a4aff to your computer and use it in GitHub Desktop.
Save fuwiak/6a79fb95d36aa73f19fe5357ff0a4aff to your computer and use it in GitHub Desktop.
def fizz_buzz(lower=1, upper=101):
return ["Fizz"*(x % 3 == 0) + "Buzz"*(x % 5 == 0) or str(x) \
for x in range(lower, upper)]
print('\n'.join(fizz_buzz()))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment