import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    }
} import java.util.*; util.* java public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    }
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    } main {
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc HashSet hs = new HashSet(); hs new HashSet() for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			hs.add(sc.nextInt());
        } {
			hs.add(sc.nextInt());
        } hs.add(sc.nextInt()) hs.add hs sc.nextInt() sc.nextInt sc System.out.println(hs.size()) System.out.println System.out System System.out hs.size() hs.size hs String[] args args public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    }
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    }
} Main
import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
        int n = sc.nextInt();
   	    HashSet hs = new HashSet();
        for(int i = 0;i < n; i++){
			hs.add(sc.nextInt());
        }
        System.out.println(hs.size());
    }
}