Passport Checking

Count how many passport numbers on a check list appear in a list of stolen numbers, counting duplicates each time.

Easy3Hash mapStringInterviewNo attempts yetTime limit1sMemory limit64 MB

Problem

This task comes from the MH370 stolen passport case.

The Interpol database holds NN passport numbers reported stolen. You are given MM more passport numbers to check. Count how many of the numbers on the check list were reported stolen.

Input

The first line contains an integer NN. (1N1000001 \le N \le 100000)

Each of the next NN lines contains one passport number reported stolen.

The next line contains an integer MM. (1M1000001 \le M \le 100000)

Each of the next MM lines contains one passport number to check.

Passport numbers consist of letters and digits only and have length at most 15. Uppercase and lowercase letters are different characters.

Output

Print on the first line how many of the MM passport numbers to check were reported stolen. If the same number appears several times on the check list, count it once for every appearance.