import java.util.*;

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

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