DictMixin providing to_dict() that returns a copy of the instance's __dict__ — then mix it into Product(DictMixin) with name and price. Mixins bundle one reusable behavior and are combined via multiple inheritance without being usable alone.Product('pen', 10).to_dict(){'name': 'pen', 'price': 10}The mixin read the instance attributes generically.
vars(self) or self.__dict__ holds instance attributes.
The mixin defines no __init__.