#include<bits/stdc++.h>
using namespace std;

#define ll long long 

int main()
{
	int n;
	cin>>n;
	int ar[n+5],mark[n+5]={0};
	for(int i=0;i<n;i++){
		cin>>ar[i];
		mark[ar[i]]=1;
	}
	for(int i=1;i<=n;i++){
		if(!mark[i]){
			cout<<"No\n";
			return 0;
		}
	}
	cout<<"Yes\n";
}
/**
 * code generated by JHelper
 * More info: https://github.com/AlexeyDmitriev/JHelper
 * @author
 */

#include <iostream>
#include <fstream>

#include <bits/stdc++.h>
using namespace std;
#define ll long long

inline int inint(istream& in) {int x; in >> x; return x;}
inline ll inll(istream& in) {ll x; in >> x; return x;}
inline string instr(istream& in) {string x; in >> x; return x;}

#define REP(i, n) for (int i = 0, i##_len = (n); i < i##_len; ++i)
#define FOR(i, a, b) for (int i = (a), i##_len = (b); i <= i##_len; ++i)
#define REV(i, a, b) for (int i = (a); i >= (b); --i)
#define CLR(a, b) memset((a), (b), sizeof(a))
#define DUMP(x) cout << #x << " = " << (x) << endl;
#define INF 1001001001001001001ll
#define fcout cout << fixed << setprecision(12)


class BPermutationCheck {
public:
void solve(std::istream& in, std::ostream& out) {
    int N = inint(in);
    vector<int> a(N, 0);


    for (int i = 0; i < N; ++i) {
        int temp = inint(in) - 1;
        a[temp] = 1;
    }

    int ok = 1;
    for(int i: a){
        if(i == 0)ok = 0;
    }

    if(ok == 1){
        out << "Yes" << endl;
    }else{
        out << "No" << endl;
    }

}
};

int main() {
	BPermutationCheck solver;
	std::istream& in(std::cin);
	std::ostream& out(std::cout);
	solver.solve(in, out);
	return 0;
}
