# coding: utf-8 # Here your code ! from collections import Counter n = int(input()) a = Counter(map(int, input().split())) sum = 0 for i in a: if a[i]==1: sum+=1 print(sum)