There are N arrays. The length of each array is M and initially each array contains integers (1，2，...，M) in this order.

Mr. Takahashi has decided to perform Q operations on those N arrays. For the i-th (1≤i≤Q) time, he performs the following operation.

* Choose an arbitrary array from the N arrays and move the integer a_i (1≤a_i≤M) to the front of that array. For example, after performing the operation on a_i=2 and the array (5，4，3，2，1), this array becomes (2，5，4，3，1).



Mr. Takahashi wants to make N arrays exactly the same after performing the Q operations. Determine if it is possible or not.

Constraints

* 2≤N≤10^5
* 2≤M≤10^5
* 1≤Q≤10^5
* 1≤a_i≤M

Input

The input is given from Standard Input in the following format:


N M
Q
a_1 a_2 ... a_Q


Output

Print `Yes` if it is possible to make N arrays exactly the same after performing the Q operations. Otherwise, print `No`.

Examples

Input

2 2
3
2 1 2


Output

Yes


Input

3 2
3
2 1 2


Output

No


Input

2 3
3
3 2 1


Output

Yes


Input

3 3
6
1 2 2 3 3 3


Output

No
#include<iostream>
#include<algorithm>
#include<vector>
#include<queue>
#include<map>
#include<set>
#include<string>
#include<stack>
#include<cstdio>
#include<cmath>
using namespace std;

typedef long long ll;
typedef long double ld;
typedef pair<ll,ll> P;
typedef pair<int,P> P1;

#define fr first
#define sc second
#define mp make_pair
#define pb push_back
#define rep(i,x) for(int i=0;i<x;i++)
#define rep1(i,x) for(int i=1;i<=x;i++)
#define rrep(i,x) for(int i=x-1;i>=0;i--)
#define rrep1(i,x) for(int i=x;i>0;i--)
#define sor(v) sort(v.begin(),v.end())
#define rev(s) reverse(s.begin(),s.end())
#define lb(vec,a) lower_bound(vec.begin(),vec.end(),a)
#define ub(vec,a) upper_bound(vec.begin(),vec.end(),a)
#define uniq(vec) vec.erase(unique(vec.begin(),vec.end()),vec.end())
#define mp1(a,b,c) P1(a,P(b,c))

const ll INF=1000000000000000000;
const int dir_4[4][2]={{1,0},{0,1},{-1,0},{0,-1}};
const int dir_8[8][2]={{1,0},{1,1},{0,1},{-1,1},{-1,0},{-1,-1},{0,-1},{1,-1}};

int main(){
	static int n,m,q;
	static int a[100010];
	scanf("%d%d%d",&n,&m,&q);
	rep(i,q)scanf("%d",&a[i]);
	
	static int b[100010];
	rep1(i,m)b[i] = q+1;
	rep(i,q)b[a[i]] = q-i;
	
	vector<P> vec;
	rep1(i,m){
		vec.pb(P(b[i],i));
	}
	sor(vec);
	static int c[100010];
	int k = 0;
	rep(i,vec.size()){
		c[vec[i].sc] = i+1;
		if(vec[i].fr != q+1)k ++;
	}
	int t = vec.size()-1;
	while(t > 0 && vec[t-1].sc < vec[t].sc)t --;
	
	//rep(i,vec.size())printf("%lld %lld\n",vec[i].fr,vec[i].sc);
	
	
	//cout << c[1] << " " << c[2] << " " << c[3] << endl;
	//cout << t << " " << k << endl;
	
	static int cnt[100010] = {};
	static bool used[100010];
	rep(i,100010)used[i] = false;
	cnt[0] = n;
	used[0] = true;
	rrep(i,q){
		if(cnt[c[a[i]]-1] > 0){
			cnt[c[a[i]]-1] --;
			cnt[c[a[i]]] ++;
			used[c[a[i]]] = true;
		}
		else {
			if(!used[c[a[i]]]){
				puts("No");
				return 0;
			}
		}
	}
	
	//cout << cnt[0] << " " << cnt[1] << " " << cnt[2] << " " << cnt[3] << endl;
	
	int ret = 0;
	for(int i = t ; i <= k ; i ++)ret += cnt[i];
	if(ret == n)puts("Yes");
	else puts("No");
}
