You are viewing a single comment's thread. Return to all comments →
My Code
N = int(input()) A = list(map(int, input().split() )) B = list(map(int, input().split() )) ans = 0; for i in range(N): for j in range(len(B)): if A[i] == B[j]: B.pop(j) ans += 1 break if ans == N: ans -= 1 else: ans += 1 print(ans)
Seems like cookies are disabled on this browser, please enable them to open this website
Beautiful Pairs
You are viewing a single comment's thread. Return to all comments →
My Code