n = int(input()) nums = list(map(int, input().split())) counter = 0 for num in nums: if nums.count(num) == 1: counter += 1 print(counter)