Quiz Catalog

Catalog of quizzes

class A(ABC):
  @abstractmethod
  def printer(self):
    print("Hello")

class B(A):
  def __init__(self):
    pass

a = A()
a.printer()

b= B()
b.printer()
Can't instantiate abstract class A with abstract methods printer
  • class/method/abstractmethod