import java.io.IOException; import java.util.Arrays; public class Main { public static void main(String[] args) throws Exception { int N = nextInt(); int[] input = new int[N]; for (int i = 0; i < N; i++) { input[i] = nextInt(); } Arrays.sort(input); int ans = 0; for (int i = 0; i < N; i++) { if ((i == 0 || input[i - 1] != input[i]) && (i == N - 1 || input[i] != input[i + 1])) { ans++; } } System.out.println(ans); } static int nextInt() { int c; try { c = System.in.read(); while (c != '-' && (c < '0' || c > '9')) c = System.in.read(); if (c == '-') return -nextInt(); int res = 0; while (c >= '0' && c <= '9') { res = res * 10 + c - '0'; c = System.in.read(); } return res; } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } return -1; } }