- if not isinstance(other, numbers.Real):
- return NotImplemented
- coordinates = self._map(lambda coordinate: coordinate / other)
- return Vector(coordinates)
-
- def __eq__(self, other):
- """
- Test whether two vectors are equal.
- """
- return isinstance(other, Vector) and \
- self._coordinates == other._coordinates
+ if isinstance(other, numbers.Real):
+ coordinates = self._map(lambda coordinate: coordinate / other)
+ return Vector(coordinates)
+ return NotImplemented