6 ms·
Well, technically the requirement is to implement both __hash__() and one of __eq__()/__cmp__(). But Python fudges this a bit in how it handles user-defined typ
by ubernostrum 17y ago
Well, technically the requirement is to implement both __hash__() and one of __eq__()/__cmp__(). But Python fudges this a bit in how it handles user-defined types.