You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
398 B
21 lines
398 B
2 years ago
|
class MADATA:
|
||
|
def __init__(
|
||
|
self,
|
||
|
a: int,
|
||
|
b: int,
|
||
|
c: int,
|
||
|
):
|
||
|
self.a = a
|
||
|
self.b = b
|
||
|
self.c = c
|
||
|
|
||
|
@property
|
||
|
def _tup_view(self):
|
||
|
return self.a, self.b, self.c
|
||
|
|
||
|
def __hash__(self):
|
||
|
return hash(self._tup_view)
|
||
|
|
||
|
def __eq__(self, o):
|
||
|
return isinstance(o, type(self)) and o._tup_view == self._tup_view
|