From fe2fb0311160440fb4a2ba782984b1c92865f91d Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Wed, 8 Dec 2021 07:22:16 +0100 Subject: Remove more useless constructors --- 2021/08/puzzle-2.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '2021/08/puzzle-2.py') diff --git a/2021/08/puzzle-2.py b/2021/08/puzzle-2.py index 74d2aad..0ebb2d3 100755 --- a/2021/08/puzzle-2.py +++ b/2021/08/puzzle-2.py @@ -39,8 +39,8 @@ def solve(nums: list[str]) -> int: acc = 0 for n, (k, v) in itertools.product(nums, nummap.items()): - if set(v) == set(n): - acc = acc * 10 + int(k) + if set(n) == v: + acc = acc * 10 + k return acc -- cgit v1.2.3