Problem Description

Read two dictionaries A and B as lists of keys. Output how many keys are present in both.

Input Format

Line1: n. Next n lines keys of A. Next line: m. Next m lines keys of B.

Output Format

One integer commonCount.

Sample Test Case

Input:
3 a b c 4 b c d a
Output:
3

Constraints

n+m

Solutions (0)

No solutions submitted yet. Be the first!

Discussion (0)

No comments yet. Start the discussion!

Prev Next