from collections import defaultdict N = int(input()) A = list(map(int,input().split())) cnt = defaultdict(int) for i in range(N): cnt[A[i]] += 1 v = list(cnt.values()) print(v.count(1))