MCPcopy Create free account
hub / github.com/ActiveState/code / __floordiv__

Method __floordiv__

recipes/Python/578006_vector/recipe-578006.py:128–131  ·  view source on GitHub ↗
(self, obj)

Source from the content-addressed store, hash-verified

126 return Vector2(self.x / obj, self.y / obj)
127
128 def __floordiv__(self, obj):
129 if isinstance(obj, Vector2):
130 return Vector2(self.x // obj.x, self.y // obj.y)
131 return Vector2(self.x // obj, self.y // obj)
132
133 def __mod__(self, obj):
134 if isinstance(obj, Vector2):

Callers

nothing calls this directly

Calls 1

Vector2Class · 0.70

Tested by

no test coverage detected