Update day23.py
This commit is contained in:
parent
8edeba4b48
commit
f1e766429d
|
@ -1,10 +1,8 @@
|
||||||
|
|
||||||
def move_cups(cups: list[int]) -> list[int]:
|
def move_cups(cups: list[int]) -> list[int]:
|
||||||
cups_round = cups[:]
|
cups_round = cups[4:]
|
||||||
current = cups_round[0]
|
current = cups[0]
|
||||||
taken = [cups_round[1], cups_round[2], cups_round[3]]
|
taken = [cups[1], cups[2], cups[3]]
|
||||||
cups_round = cups_round[4:]
|
|
||||||
|
|
||||||
minimum, maximum = min(cups_round), max(cups_round)
|
minimum, maximum = min(cups_round), max(cups_round)
|
||||||
|
|
||||||
destination = current
|
destination = current
|
||||||
|
@ -33,6 +31,3 @@ def solve_p1(order: str, n: int) -> str:
|
||||||
|
|
||||||
|
|
||||||
print(solve_p1("389547612", 100))
|
print(solve_p1("389547612", 100))
|
||||||
|
|
||||||
|
|
||||||
# TODO: Part 2 should use different data structure
|
|
||||||
|
|
Loading…
Reference in a new issue