Shorten 4-1

master
Valentin Ochs 2020-12-04 17:28:58 +01:00
parent 4fa675f155
commit 4eb36eacd0
1 changed files with 1 additions and 1 deletions

View File

@ -1 +1 @@
print(sum(map(lambda x:7==len(set(['byr','iyr','eyr','hgt','hcl','ecl','pid'])&set(map(lambda y:y[:3],x.replace('\n',' ').split(' ')))),open(0).read().split("\n\n"))))
print(sum(map(lambda x:6<len(''.join(sorted(map(lambda y:y[:2].replace('ci','')[:1],x.split())))),open(0).read().split('\n'*2))))