From 1b47a4e379fe880f856187a78a6904995b39b075 Mon Sep 17 00:00:00 2001 From: Valentin Ochs Date: Sun, 6 Dec 2020 13:15:58 +0100 Subject: [PATCH] Reduce 6-2 --- 06-2-1.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/06-2-1.py b/06-2-1.py index feef9d8..bfbdcad 100644 --- a/06-2-1.py +++ b/06-2-1.py @@ -1 +1 @@ -print(sum(map(lambda x:sum((f:=x.count)(c)==(t:=f('\n')+1)for c in x)//t,open(0).read()[:-1].split('\n'*2)))) +print(sum(map(lambda x:sum((f:=x.count)(c)>f('\n')for c in set(x)),open(0).read()[:-1].split('\n'*2))))