diff --git a/day-21/day-21.py b/day-21/day-21.py index f343a24..6c92b95 100644 --- a/day-21/day-21.py +++ b/day-21/day-21.py @@ -16,8 +16,8 @@ def quantum_roll(state, p0, p1, s0, s1): for d2 in [1, 2, 3]: new_p0 = (p0 + d0 + d1 + d2) % 10 new_s0 = s0 + new_p0 + 1 - (x1, y1) = quantum_roll(state, p1, new_p0, s1, new_s0) - res = (res[0] + y1, res[1] + x1) + (w1, w0) = quantum_roll(state, p1, new_p0, s1, new_s0) + res = (res[0] + w0, res[1] + w1) state[(p0, p1, s0, s1)] = res return res