Find the number of commom characters in two strings
Input
The first line of the input contains an integer T, denoting the number of test
cases. Then the description of T test cases follows.
The first line of each test case contains a string A. The next line contains
another character string B.
Output
For each test case, output a single line containing a single integer, the common
characters in A and B.
Constraints
1 ≤ T ≤ 100
1 ≤ |A|, |B| ≤ 10000
ST:
4
abcd
xyz
abcd
bcda
apbc
akbc
moedhecf
elfedcc
SO:
0
4
3
5
Exp:
Example case 1. There is no common character.
Example case 2. All the characters are same.
Example case 3. Three characters (a, b and c) are same.
TC1:
2
abcdefrstuvwxyz
abghijklmnrstuv
qwerty
uiopwefghj
OP1:
7
2
TC2:
2
aaaa
bbbb
aaaa
aaaa
OP2:
0
4
TC3:
2
abcdefghijklmn
owierpoiweopij
xcbzlkjxbclkjb
posidhfoisdfhh
OP3:
3
0
TC4:
2
aabbccddeeeeeffffffggggg
aabbccddeeffffffgggghhhh
abcdefgghhiijjkkllmmmm
abcdmmmhijk
OP4:
20
11