Skip to content

Instantly share code, notes, and snippets.

@liweinan
Created April 1, 2018 13:18
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 liweinan/2868bb926529a240264751858b0a731f to your computer and use it in GitHub Desktop.
Save liweinan/2868bb926529a240264751858b0a731f to your computer and use it in GitHub Desktop.
class Restaurant():
def __init__(self, my_name, my_type):
self.my_name = my_name
self.my_type = my_type
def desc(self):
print("Name: " + self.my_name + " Type: " + self.my_type)
my_restaurant = Restaurant("Mars", "Huge")
my_restaurant.desc()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment