Guest User

Untitled

a guest
Feb 17th, 2019
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. from abc import ABCMeta, abstractmethod
  2. class LinearModel(metaclass = ABCMeta):
  3.  
  4. @abstractmethod
  5. def fit(self):
  6. print('Hello')
  7.  
  8. class LinearRegression(LinearModel):
  9.  
  10. def fit(self):
  11. print('Bye')
  12.  
  13. c = LinearRegression()
  14. c.fit()
  15.  
  16. # Output
  17. Bye
Add Comment
Please, Sign In to add comment