7 lines
183 B
Python
7 lines
183 B
Python
|
#!/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()))))))
|