Skip to content

Instantly share code, notes, and snippets.

@vereperrot
Created April 28, 2020 12:24
Show Gist options
  • Save vereperrot/9298621733cef30525a8c770f36004ec to your computer and use it in GitHub Desktop.
Save vereperrot/9298621733cef30525a8c770f36004ec to your computer and use it in GitHub Desktop.
describe_pet
def describe_pet(pet_name,animal_type='dog'):
"""show pet information"""
text="\n I have a "+animal_type+"."
text+="\n My "+animal_type+"'s name is "+pet_name.title()+"."
print(text)
return text
describe_pet(pet_name="harry")
"""
OUTPUT:
I have a dog.
My dog's name is Harry.
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment