Skip to content

Instantly share code, notes, and snippets.

@chipoglesby
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chipoglesby/51c26f6a22ef8d90913a to your computer and use it in GitHub Desktop.
Save chipoglesby/51c26f6a22ef8d90913a to your computer and use it in GitHub Desktop.
Python Examples
def donuts(count):
if count >= 10:
return 'Number of donuts: many'
else:
return 'Number of donuts: %s' % count
def donuts(count):
text1 = 'Number of donuts: '
if count<10:
text = text1 + str(count)
else:
text = text1 + 'many'
return text
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment