Can abstract class have variables in Python?

Abstract class cannot be instantiated but it can be subclassed. In subclass need to provide definition for abstract methods. Abstract class can have member variables that can be used in subclasses .

Sizin İçin Seçtik  Can an abstract class be used as a parameter type for methods?

Leave a Reply

Your email address will not be published. Required fields are marked *