import java.util.*;
import java.util.stream.Collectors;

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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	}
} import java.util.*; util.* java import java.util.stream.Collectors; Collectors java.util.stream 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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	}
} 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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	} 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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	} 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 list = list.stream().distinct().collect(Collectors.toList()) list list.stream().distinct().collect(Collectors.toList()) list.stream().distinct().collect list.stream().distinct() list.stream().distinct list.stream() list.stream list Collectors.toList() Collectors.toList Collectors System.out.println(list.size()) System.out.println System.out System System.out list.size() list.size 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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	}
} 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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	}
} Main
import java.util.*;
import java.util.stream.Collectors;

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());
		}
		list = list.stream().distinct().collect(Collectors.toList());
		System.out.println(list.size());
	}
}
