import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	}

} import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	}

} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	} main {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) List<Integer> list = new ArrayList<>(); list new ArrayList<>() int num = scan.nextInt(); num scan.nextInt() scan.nextInt scan for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		} int i = 0; int i = 0; i 0 i < num i num i++ i++ i {
			list.add(scan.nextInt());
		} {
			list.add(scan.nextInt());
		} list.add(scan.nextInt()) list.add list scan.nextInt() scan.nextInt scan long count = list.stream().distinct().count(); count list.stream().distinct().count() list.stream().distinct().count list.stream().distinct() list.stream().distinct list.stream() list.stream list System.out.println(count) System.out.println System.out System System.out count scan.close() scan.close scan String[] args args public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	}

} public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	}

} Main
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<>();		// 整数列

		int num = scan.nextInt();					// 整数の個数
		for(int i = 0; i < num; i++) {
			list.add(scan.nextInt());
		}

		long count = list.stream().distinct().count();
		System.out.println(count);

		scan.close();

	}

}