input() A = list(map(int, input().split())) A.sort() kind = list(set(A)) res = 0 for k in kind: if A.count(k) == 1: res += 1 print(res)