Advertisement
Guest User

Untitled

a guest
Mar 31st, 2020
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.36 KB | None | 0 0
  1. #HardwareStore subclass inherited from Store superclass
  2. class HardwareStore(Store):
  3.     pass
  4.  
  5. #new instance of HardwareStore class with variable name home_depot
  6. home_depot = HardwareStore()
  7. #accessing the Store owner attribute from
  8. #the HardwareStore instance
  9. home_depot.owner
  10. #accessing the exclaim method from the
  11. #HardwareStore instance
  12. home_depot.exclaim()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement