diff --git a/2024/06/part1.py b/2024/06/part1.py index d676e6e..ac918bf 100644 --- a/2024/06/part1.py +++ b/2024/06/part1.py @@ -72,7 +72,7 @@ class Map: guard_locations = [] for direction in self.directions: - guard_locations.extend(list(zip(*np.where(m.map == direction)))) + guard_locations.extend(list(zip(*np.where(self.map == direction)))) return guard_locations def load_map(self, filename="input"): @@ -96,7 +96,7 @@ class Map: self.pos = guards[0] self.trace.append(self.pos) - self.direction = m.map[self.pos] + self.direction = self.map[self.pos] # TODO: Use enum. #self.map[self.pos] = self.Tiles.FREE self.map[self.pos] = "."