from collections import Counter n = int(input()) an = input().split() cnt = Counter(an) a = [i for i in cnt.items() if i[1] == 1] print(len(a))