import java.util.*;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Set<Integer> d = new HashSet<>();
    for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    }
    System.out.println(d.size());
  }
} import java.util.*; util.* java class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Set<Integer> d = new HashSet<>();
    for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    }
    System.out.println(d.size());
  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Set<Integer> d = new HashSet<>();
    for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    }
    System.out.println(d.size());
  } main {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Set<Integer> d = new HashSet<>();
    for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    }
    System.out.println(d.size());
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc Set<Integer> d = new HashSet<>(); d new HashSet<>() for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
        d.add(sc.nextInt());
    } {
        d.add(sc.nextInt());
    } d.add(sc.nextInt()) d.add d sc.nextInt() sc.nextInt sc System.out.println(d.size()) System.out.println System.out System System.out d.size() d.size d String[] args args
import java.util.*;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Set<Integer> d = new HashSet<>();
    for (int i = 0; i < n; i++) {
        d.add(sc.nextInt());
    }
    System.out.println(d.size());
  }
}