Skip to content

Commit 647af8c

Browse files
authored
Update lib.py
1 parent c40bf7c commit 647af8c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

linear_algebra/src/lib.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -187,11 +187,11 @@ def __eq__(self, vector: Vector) -> bool:
187187
"""
188188
performs the comparison between two vectors
189189
"""
190-
if not isinstance(other, Vector):
190+
if not isinstance(vector, Vector):
191191
return NotImplemented
192-
if len(self) != len(other):
192+
if len(self) != len(vector):
193193
return False
194-
return all(self.component(i) == other.component(i) for i in range(len(self)))
194+
return all(self.component(i) == vector.component(i) for i in range(len(self)))
195195

196196

197197
def zero_vector(dimension: int) -> Vector:

0 commit comments

Comments
 (0)