MCPcopy Create free account
hub / github.com/AxlLind/AdventOfCode / part1

Function part1

2018/src/11.py:4–9  ·  view source on GitHub ↗
(dp: list[list[list[int]]])

Source from the content-addressed store, hash-verified

2from itertools import product
3
4def part1(dp: list[list[list[int]]]) -> str:
5 xmax,ymax,v = 0,0,0
6 for x,y in product(range(1,297), repeat=2):
7 if dp[x][y][3] > v:
8 xmax,ymax,v = x,y,dp[x][y][3]
9 return f"{xmax},{ymax}"
10
11def part2(dp: list[list[list[int]]]) -> str:
12 xmax,ymax,sizemax,v = 0,0,0,0

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected