n = int(input()) a = list(map(int,input().split())) x = 0 for i in range(n): if a.count(a[i]) == 1: x += 1 print(x)