Behaviour of set-intersection of objects
Behaviour of set-intersection of objects Question: I stumbled upon this uncertainty in one of my programs: Suppose we have a Class deriving from int with a custom attribute. class A(int): def __new__(cls, value, *args, **kwargs): return super(cls, cls).__new__(cls, value) def __init__(self, _, a): self.a = a Objects of this class are now used in a …