Пример #1
0
 def test_make_vector(self):
     v1 = Vector.make_vector(self.n1, self.n2, 0)
     v2 = Vector((self.n1, self.n2), 0)
     self.assertEqual(v1, v2)
Пример #2
0
 def __make_path(self, neighbors):
     vectors_to_neighbors = set()
     for neighbor in neighbors:
         vectors_to_neighbors.add(Vector.make_vector(self, neighbor, 1))
     return vectors_to_neighbors