Skip to content

Instantly share code, notes, and snippets.

@radupotop
Created April 6, 2012 07:20
Show Gist options
  • Save radupotop/2317895 to your computer and use it in GitHub Desktop.
Save radupotop/2317895 to your computer and use it in GitHub Desktop.
fizzbuzz_
def fizzbuzz(n):
if n % 15 == 0:
print 'fizzbuzz'
elif n % 3 == 0:
print 'fizz'
elif n % 5 == 0:
print 'buzz'
else:
print n
for i in xrange(1,16):
fizzbuzz(i)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment