Created
May 30, 2022 06:14
-
-
Save BekBrace/3290de96d804c54d8cacee812e867002 to your computer and use it in GitHub Desktop.
FizzBuzz in Python
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
for fizzbuzz in range(51): | |
if fizzbuzz % 3 == 0 and fizzbuzz % 5 == 0: | |
print("fizzbuzz") | |
continue | |
elif fizzbuzz % 3 == 0: | |
print("fizz") | |
continue | |
elif fizzbuzz % 5 == 0: | |
print("buzz") | |
continue | |
print(fizzbuzz) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
silly question that interviewers like to ask