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

 
public class Main {
 
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	}
} import java.util.ArrayList; ArrayList java.util import java.util.Scanner; Scanner java.util public class Main {
 
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	}
} Main public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	} main {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc ArrayList<Integer> numList = new ArrayList<>(); numList new ArrayList<>() int ans = 0; ans 0 for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			numList.add(sc.nextInt());
		} {
			numList.add(sc.nextInt());
		} numList.add(sc.nextInt()) numList.add numList sc.nextInt() sc.nextInt sc int min = numList.get(0); min numList.get(0) numList.get numList 0 for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		} {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		} if(numList.get(i) < min) {
				min = numList.get(i);
			} numList.get(i) < min numList.get(i) numList.get numList i min {
				min = numList.get(i);
			} min = numList.get(i) min numList.get(i) numList.get numList i if(numList.get(i) <= min) {
				ans++;
			} numList.get(i) <= min numList.get(i) numList.get numList i min {
				ans++;
			} ans++ ans System.out.println(ans) System.out.println System.out System System.out ans sc.close() sc.close sc String[] args args public class Main {
 
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	}
} public class Main {
 
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	}
} Main
import java.util.ArrayList;
import java.util.Scanner;

 
public class Main {
 
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		ArrayList<Integer> numList = new ArrayList<>();
		int ans = 0;
		
		for(int i = 0; i < N; i++) {
			numList.add(sc.nextInt());
		}
		
		int min = numList.get(0);
		for(int i = 0; i < N; i++) {
			if(numList.get(i) < min) {
				min = numList.get(i);
			}
			
			if(numList.get(i) <= min) {
				ans++;
			}
		}
		
		System.out.println(ans);
		sc.close();
	}
}