#include <bits/stdc++.h>
using namespace std;
char b[26];
int y = 0;
bool check(char a) {
  for (int i = 0; i < 26; i++) {
    if (b[i] == a) {
      return false;
    }
  }
  b[y] = a;
  y++;
  return true;
}
int main() {
  int n, k;
  cin >> n >> k;
  string a;
  cin >> a;
  int g = k;
  string ans = "NO";
  int d[26];
  for (int i = 0; i < 26; i++) {
    d[i] = 0;
  }
  for (int i = 0; i < n; i++) {
    d[a[i] - 65]++;
  }
  for (int i = 0; i < n; i++) {
    if (check(a[i])) {
      g--;
      d[a[i] - 65]--;
      if (g < 0) {
        ans = "YES";
        break;
      }
      if (d[a[i] - 65] == 0) {
        g++;
      }
    } else {
      d[a[i] - 65]--;
      if (d[a[i] - 65] == 0) {
        g++;
      }
    }
    if (g < 0) {
      ans = "YES";
      break;
    }
  }
  cout << ans << endl;
  return 0;
}
