Solve day 18 and 19 2017.

This commit is contained in:
2024-05-30 09:01:51 -04:00
parent 5b7b9c87cb
commit ecda947fb4
4 changed files with 166 additions and 1 deletions

View File

@@ -27,6 +27,9 @@ def mape(f, xs):
def add2(a: tuple[int, int], b: tuple[int, int]) -> tuple[int, int]:
return (a[0] + b[0], a[1] + b[1])
def sub2(a: tuple[int, int], b: tuple[int, int]) -> tuple[int, int]:
return (a[0] - b[0], a[1] - b[1])
class Grid2D:
N = (-1, 0)
E = (0, 1)