from collections import Counter N = int(input()) A = Counter(map(int, input().split())) answer = len([1 for val in A.values() if val == 1]) print(answer)