N=int(input()) D={} L=list(map(int,input().split())) for i in L: if i not in D: D[i]=1 else: D[i]+=1 ans=0 for k,v in D.items(): if v==1: ans+=1 print(ans)