import java.math.*;
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    }
} import java.math.*; math.* java import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int p[] = new int[n]; p new int[n] n int cnt = 1; cnt 1 for(int i=0;i<n;i++)
            p[i] = sc.nextInt(); int i=0; int i=0; i 0 i<n i n i++ i++ i p[i] = sc.nextInt(); p[i] = sc.nextInt() p[i] p i sc.nextInt() sc.nextInt sc int tmp = p[0]; tmp p[0] p 0 for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        } int i = 1; int i = 1; i 1 i < n i n i++ i++ i {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        } {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        } if (tmp > p[i])
                cnt++; tmp > p[i] tmp p[i] p i cnt++ cnt if (p[i] < tmp)
                tmp = p[i]; p[i] < tmp p[i] p i tmp tmp = p[i] tmp p[i] p i System.out.println(cnt) System.out.println System.out System System.out cnt String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    }
} Main
import java.math.*;
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int p[] = new int[n];
        int cnt = 1;
        ;
        for(int i=0;i<n;i++)
            p[i] = sc.nextInt();
        int tmp = p[0];
        for (int i = 1; i < n; i++) {
            if (tmp > p[i])
                cnt++;
            if (p[i] < tmp)
                tmp = p[i];
        }
        System.out.println(cnt);
    }
}