From c1f46f9fce73921273321bbda760200750d4614c Mon Sep 17 00:00:00 2001 From: Luke Hubmayer-Werner Date: Tue, 20 Dec 2022 02:39:53 +1030 Subject: [PATCH] no need to check length --- 2022/day19.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/2022/day19.py b/2022/day19.py index 2888180..1716023 100644 --- a/2022/day19.py +++ b/2022/day19.py @@ -35,7 +35,7 @@ def bp_quality(line, t_max=24): add_state(0, np.array((1,0,0), dtype=np.int8), np.array((0,0,0), dtype=np.int8), 0) geodes_best = 0 - while len(search_stack) > 0: + while search_stack: t, robot_counts, res_counts, geodes_total = search_stack.pop() if t < t_max: if (geodes_total + maximum_potential[t_max-t]) < geodes_best: