Skip to content

Instantly share code, notes, and snippets.

@tommeagher
Created June 17, 2013 17:00
Show Gist options
  • Save tommeagher/5798410 to your computer and use it in GitHub Desktop.
Save tommeagher/5798410 to your computer and use it in GitHub Desktop.
Fizzbuzz.py
for x in range(101)[1:]:
if x % 3 == 0:
print "Fizz"
if x % 5 == 0:
print "Buzz"
if x % 5 == 0 and x % 3 == 0:
print "FizzBuzz"
else:
print x
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment