Skip to content

Instantly share code, notes, and snippets.

@pknowledge
Created September 12, 2018 20:57
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 pknowledge/c4d6c697633491e44c277db070d7445a to your computer and use it in GitHub Desktop.
Save pknowledge/c4d6c697633491e44c277db070d7445a to your computer and use it in GitHub Desktop.
python Class example
class Rectangle:
pass
rect1 = Rectangle()
rect2 = Rectangle()
rect1.height = 20
rect2.height = 30
rect1.width = 40
rect2.width = 10
print(rect1.height * rect1.width)
print(rect2.height * rect2.width)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment