input() As = input().split() d = {} for A in As: if A not in d: d[A] = 0 d[A] += 1 c = 0 for v in d.values(): if v == 1: c += 1 print(c)