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<cstring>
#include<cstdio>
#include<vector>
#include<cmath>
#include<algorithm>
#include<functional>
#include<iomanip>
#include<queue>
#include<ciso646>
#include<map>
#include<set>
#include<complex>
#include<bitset>
#include<stack>
#include<utility>
#include<random>
#include<unordered_map>
using namespace std;
typedef long long ll;
typedef unsigned int ui;
const ll mod = 1000000007;
const ll INF = (ll)1000000007 * 1000000007;
typedef pair<int, int> P;
#define stop char nyaa;cin>>nyaa;
#define rep(i,n) for(int i=0;i<n;i++)
#define per(i,n) for(int i=n-1;i>=0;i--)
#define Rep(i,sta,n) for(int i=sta;i<n;i++)
#define rep1(i,n) for(int i=1;i<=n;i++)
#define per1(i,n) for(int i=n;i>=1;i--)
#define Rep1(i,sta,n) for(int i=sta;i<=n;i++)
typedef long double ld;
typedef complex<ld> Point;
const ld eps = 1e-2;
const ld pi = acos(-1.0);
typedef pair<ll, ll> LP;

int a[1 << 17];
bool used[1 << 17];
vector<int> v;
int c[1 << 17];
int inv[1 << 17];
int main() {
	int n, m, q;
	cin >> n >> m >> q;
	rep(i, q) {
		cin >> a[i];
	}
	per(i, q) {
		if (used[a[i]])continue;
		used[a[i]] = true;
		v.push_back(a[i]);
	}
	rep1(i, m) {
		if (used[i])continue;
		v.push_back(i);
	}
	int ri = 0;
	rep(i, m - 1) {
		if (v[i] > v[i + 1]) {
			ri = i + 1;
		}
	}
	rep(i, m) {
		inv[v[i]] = i;
	}
	bool f = true;
	per(i, q) {
		int id = inv[a[i]];
		if (id >= ri)continue;
		if (id > 0) {
			if (c[id - 1] > c[id]) {
				c[id]++;
			}
		}
		else c[id]++;
	}
	rep(i, ri) {
		if (c[i] < n)f = false;
	}
	if (f)cout << "Yes" << endl;
	else cout << "No" << endl;
	//stop
	return 0;
}
