#include <bits/stdc++.h>
using namespace std;
int n, k;
string str;
vector<int> Time, first, last;
int main() {
  cin >> n >> k >> str;
  Time.assign(str.size() + 1, 0), first.assign(26, 1 << 30),
      last.assign(26, -1);
  for (int i = 0, j; i < str.size(); i++)
    j = str[i] - 'A', first[j] = min(first[j], i), last[j] = i;
  for (int i = 0; i < 26; i++)
    if (last[i] != -1) Time[first[i]] += 1, Time[last[i] + 1] += -1;
  int cur = 0, Max = 0;
  for (int i = 0; i < str.size(); i++) cur += Time[i], Max = max(Max, cur);
  if (Max > k)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
