import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(), min = Integer.MAX_VALUE, max = Integer.MIN_VALUE, cnt = 0; int[] a = new int[N]; for(int i = 0; i < N; i++) { a[i] = sc.nextInt(); min = Math.min(min, a[i]); max = Math.max(max, a[i]); } int[] A = new int[max - min + 1]; for(int i = 0; i < N; i++) { A[a[i] - 1]++; } for(int i = 0; i < A.length; i++) { if(A[i] == 1) cnt++; } System.out.println(cnt); } }