diff --git a/day-10/day-10.py b/day-10/day-10.py index 2328279..5eb6b59 100644 --- a/day-10/day-10.py +++ b/day-10/day-10.py @@ -27,19 +27,18 @@ def part_1(input): def part_2(input): result = 0 - lines = input.copy() scores = [] - for line in input: + for line in input.copy(): seen = [] for c in line.rstrip(): if c in o_chars: seen.append(c) elif o_chars.index(seen[-1]) != c_chars.index(c): - lines.remove(line) + input.remove(line) break else: del seen[-1] - for line in lines: + for line in input: seen = [] for c in line.rstrip(): if c in o_chars: