#include <iostream>
#include <map>

using namespace std;

int main() {
  int n; cin >> n;

  map<int, int> mp;
  for (int i = 0; i < n; i++) {
    int a; cin >> a;
    mp[a]++;
  }
  cout << ( mp.size() == n ? "YES" : "NO") << endl;

  return 0;
}