import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	}


} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {

	public static void main(String[] args) throws Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	}


} Main public static void main(String[] args) throws Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	} main {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	} BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); in new BufferedReader(new InputStreamReader(System.in)) String W = in.readLine(); W in.readLine() in.readLine in int N = Integer.parseInt(W); N Integer.parseInt(W) Integer.parseInt Integer W W = in.readLine() W in.readLine() in.readLine in String[] Ws = W.split(" "); Ws W.split(" ") W.split W " " int[] P = new int[N]; P new int[N] N for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			P[i] = Integer.parseInt(Ws[i]);
		} {
			P[i] = Integer.parseInt(Ws[i]);
		} P[i] = Integer.parseInt(Ws[i]) P[i] P i Integer.parseInt(Ws[i]) Integer.parseInt Integer Ws[i] Ws i int ans =0; ans 0 int Pj =Integer.MAX_VALUE; Pj Integer.MAX_VALUE Integer Integer.MAX_VALUE for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		} {
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		} if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			} P[i]<=Pj P[i] P i Pj {
				ans++;
				Pj=P[i];
			} ans++ ans Pj=P[i] Pj P[i] P i 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 Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	}


} public class Main {

	public static void main(String[] args) throws Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	}


} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws Exception {
		// TODO 自動生成されたメソッド・スタブ
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String W = in.readLine();
		int N = Integer.parseInt(W);

		W = in.readLine();
		String[] Ws = W.split(" ");

		int[] P = new int[N];

		for(int i=0;i<N;i++){
			P[i] = Integer.parseInt(Ws[i]);
		}

		int ans =0;
		int Pj =Integer.MAX_VALUE;
		for(int i=0;i<N;i++){
			if(P[i]<=Pj){
				ans++;
				Pj=P[i];
			}
		}

		System.out.println(ans);



	}


}
