Advent-of-Code/2020/day 6/P1/custom_customs.py
2020-12-06 12:00:45 +01:00

10 lines
215 B
Python

qs = []
with open("input.txt") as f:
for q in f.read().split("\n\n"):
s = set()
for a in q.split("\n"):
s.update(list(a))
qs.append(s)
print(sum(map(lambda x: len(x), qs)))