Skip to content

Instantly share code, notes, and snippets.

@colonelpanic8
Last active October 2, 2016 09:56
Show Gist options
  • Select an option

  • Save colonelpanic8/5021532 to your computer and use it in GitHub Desktop.

Select an option

Save colonelpanic8/5021532 to your computer and use it in GitHub Desktop.
We couldn’t find any files to show.
@MttWld

MttWld commented Feb 23, 2013

Copy link
Copy Markdown

import sys
x = sys.argv[2]

def fizz_buzz(x):
for i in range(1,x):
if i % 3 == 0 and i % 5 == 0:
print "FizzBuzz"
elif i % 3 == 0:
print "Fizz"
elif i % 5 == 0:
print 'Buzz'
else:
print i

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment