input() nums = [int(i) for i in input().split()] l = sum(True for i in set(nums) if nums.count(i) == 1) print(l)