diff options
Diffstat (limited to 'codechef/chefing.py')
-rwxr-xr-x | codechef/chefing.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/codechef/chefing.py b/codechef/chefing.py new file mode 100755 index 0000000..e3c71a1 --- /dev/null +++ b/codechef/chefing.py @@ -0,0 +1,6 @@ +#!/usr/bin/env python3 +from functools import reduce +from operator import and_ + +for _ in range(int(input())): + print(len(reduce(and_, (set(input()) for _ in range(int(input())))))) |