advanced programming techniques abc statement which is needed for the abstractmethod(and abstractproperty(functionsboth of which can be used as decoratorsclass appliance(metaclass=abc abcmeta)@abc abstractmethod def __init__(selfmodelprice)self __model model self price price def get_price(self)return self __price def set_price(selfprice)self __price price price abc abstractproperty(get_priceset_price@property def model(self)return self __model we have set the class' metaclass to be abc abcmeta since this is requirement for abcsany abc abcmeta subclass can be used insteadof course we have made __init__(an abstract method to ensure that it is reimplementedand we have also provided an implementation which we expect (but can' forceinheritors to call to make an abstract readable/writable property we cannot use decorator syntaxalso we have not used private names for the getter and setter since doing so would be inconvenient for subclasses the price property is abstract (so we cannot use the @property decorator)and is readable/writable here we follow common pattern for when we have private readable/writable data ( __priceas propertywe initialize the property in the __init__(method rather than setting the private data directly--this ensures that the setter is called (and may potentially do validation or other workalthough it doesn' in this particular examplethe model property is not abstractso subclasses don' need to reimplement itand we can make it property using the @property decorator here we follow common pattern for when we have private read-only data ( __modelas propertywe set the private __model data once in the __init__(methodand provide read access via the read-only model property note that no appliance objects can be createdbecause the class contains abstract attributes here is an example subclass