import java.util.Scanner;
import java.util.Set;
import java.util.TreeSet;

public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    }
} import java.util.Scanner; Scanner java.util import java.util.Set; Set java.util import java.util.TreeSet; TreeSet java.util public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    } main {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = Integer.parseInt(sc.nextLine()); N Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc Set<Integer> set = new TreeSet<>(); set new TreeSet<>() for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            set.add(Integer.parseInt(sc.nextLine()));
        } {
            set.add(Integer.parseInt(sc.nextLine()));
        } set.add(Integer.parseInt(sc.nextLine())) set.add set Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc int ans = 0; ans 0 int before = 0; before 0 for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        } Integer current set {
            if (before < current) {
                ans++;
            }
        } {
            if (before < current) {
                ans++;
            }
        } if (before < current) {
                ans++;
            } before < current before current {
                ans++;
            } ans++ ans System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    }
} public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    }
} Main
import java.util.Scanner;
import java.util.Set;
import java.util.TreeSet;

public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int N = Integer.parseInt(sc.nextLine());
        Set<Integer> set = new TreeSet<>();
        for (int i = 0; i < N; i++) {
            set.add(Integer.parseInt(sc.nextLine()));
        }

        int ans = 0;
        int before = 0;
        for (Integer current : set) {
            if (before < current) {
                ans++;
            }
        }
        System.out.println(ans);
    }
}
