import java.util.Scanner;
import java.io.File;
import java.io.FileNotFoundException;

public class Main
{
  public static void main(String[] args) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  }
} import java.util.Scanner; Scanner java.util import java.io.File; File java.io import java.io.FileNotFoundException; FileNotFoundException java.io public class Main
{
  public static void main(String[] args) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  }
} Main public static void main(String[] args) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  } main {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int n = scanner.nextInt(); n scanner.nextInt() scanner.nextInt scanner int[] arr = new int[n]; arr new int[n] n for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    } int i = 0 ; int i = 0 ; i 0 i < n i n i++ i++ i {
      arr[i] = scanner.nextInt();
    } {
      arr[i] = scanner.nextInt();
    } arr[i] = scanner.nextInt() arr[i] arr i scanner.nextInt() scanner.nextInt scanner int min = (1 << 30) min (1 << 30) 1 30 ans = 0; ans 0 for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    } int i = 0 ; int i = 0 ; i 0 i < n i n i++ i++ i {
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    } {
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    } if(arr[i] < min){
        min = arr[i];
        ans += 1;
      } arr[i] < min arr[i] arr i min {
        min = arr[i];
        ans += 1;
      } min = arr[i] min arr[i] arr i ans += 1 ans 1 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) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  }
} public class Main
{
  public static void main(String[] args) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  }
} Main
import java.util.Scanner;
import java.io.File;
import java.io.FileNotFoundException;

public class Main
{
  public static void main(String[] args) throws FileNotFoundException
  {
    Scanner scanner = new Scanner(System.in);//new File("input.txt"));
    int n = scanner.nextInt();
    int[] arr = new int[n];
    for(int i = 0 ; i < n ; i++){
      arr[i] = scanner.nextInt();
    }

    int min = (1 << 30), ans = 0;
    for(int i = 0 ; i < n ; i++){
      if(arr[i] < min){
        min = arr[i];
        ans += 1;
      }
    }
    System.out.println(ans);
  }
}
