main
magical 2022-11-30 21:13:15 -08:00
parent d4739b512d
commit 64779081cb
2 changed files with 2263 additions and 0 deletions

2248
day01/input 100644

File diff suppressed because it is too large Load Diff

15
day01/sol.py 100644
View File

@ -0,0 +1,15 @@
def parse(f):
data = []
for chunk in f.read().split("\n\n"):
data.append([int(x) for x in chunk.split()])
return data
with open("input") as f:
data = parse(f)
sums = [sum(x) for x in data]
print(max(sums))
sums.sort()
print(sum(sums[-3:]))