import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	} main {
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int[] ary=new int[a]; ary new int[a] a for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      } int i=0; int i=0; i 0 i < a i a i++ i++ i {
        ary[i]=sc.nextInt();
      } {
        ary[i]=sc.nextInt();
      } ary[i]=sc.nextInt() ary[i] ary i sc.nextInt() sc.nextInt sc int ans=0; ans 0 int min=2000000; min 2000000 int max=0; max 0 for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      } int i=0; int i=0; i 0 i < a i a i++ i++ i {
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      } {
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      } if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        } ary[i]<min ary[i] ary i min {
          ans++;
          min=ary[i];
        } ans++ ans min=ary[i] min ary[i] ary i if (true) {
        } true {
        } 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 a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	}
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	}
} Main
import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
      		int a = sc.nextInt();


      int[] ary=new int[a];
      for (int i=0; i < a;i++){
        ary[i]=sc.nextInt();
      }
	int ans=0;      
    int min=2000000;
      int max=0;
      for (int i=0; i < a;i++){
        if (ary[i]<min){
          ans++;
          min=ary[i];
        } else if (true) {
        }
      }
		System.out.println(ans);
	}
}