import java.util.*;
import java.util.Collections;

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

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