import java.util.*;
public class Main {
	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    }
    
} import java.util.*; util.* java public class Main {
	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    }
    
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    } main {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc List<Integer> list = new ArrayList<>(N); list new ArrayList<>(N) for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
        	list.add(sc.nextInt());
        } {
        	list.add(sc.nextInt());
        } list.add(sc.nextInt()) list.add list sc.nextInt() sc.nextInt sc System.out.println(list.stream().distinct().count()) System.out.println System.out System System.out list.stream().distinct().count() list.stream().distinct().count list.stream().distinct() list.stream().distinct list.stream() list.stream list String[] args args public class Main {
	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    }
    
} public class Main {
	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    }
    
} Main
import java.util.*;
public class Main {
	
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        
        List<Integer> list = new ArrayList<>(N);
        for (int i = 0; i < N; i++) {
        	list.add(sc.nextInt());
        }
        
        System.out.println(list.stream().distinct().count());
    }
    
}