#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  string s;
  cin >> n >> s;
  if (n == 1)
    cout << "YES";
  else {
    for (int i = 0; i < n; i++) {
      for (int j = i + 1; j < n; j++) {
        if (s[i] == s[j]) {
          cout << "YES";
          return 0;
        }
      }
    }
    cout << "NO";
  }
  return 0;
}
