Advertisement
Guest User

Untitled

a guest
Dec 24th, 2020
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.21 KB | None | 0 0
  1. class Animal:
  2.     name = "Antony"
  3.     species = "Cat"
  4.     limbs = 4
  5.  
  6. dog = Animal()
  7. cat = Animal()
  8.  
  9. # This DOES work (So why is this a "static" member)
  10. dog.limbs = 3
  11. # Actually makes sense
  12. Animal.limbs = 3
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement