a=int(input()) b=[int(i) for i in input().split()] c=0 for i in range(a): if b.count(b[i])==1: c+=1 print(c)