Given a string, count the number of aplhabets which are repeated
 

Input
The first line contains a single integer T <= 40, the number of test cases. T test cases follow. The only line of each test case contains a non-empty text composed only of letters of English alphabet. The length of the text is less then 100. There are no any spaces in the input..

Output
For each test case, output a single line containing the number of  alphabets that are repeated in the corresponding text.


Example
Input:
3
aalmlc
aPlmFl
XcCnLb

Output:
2
1
1
n=input()
for i in range(n):
    string1=raw_input().lower()
    count=0
    for y in range (97,122):
        if string1.count(chr(y))>1:
            count+=1
    print count