n = int(input()) a = list(map(int, input().split())) b = list(map(int, input().split())) d = 0 ans = 0 for i in range(n): s = (a - b) % 2 if d == s: continue d = s ans += s print(ans)