433 3
FZDDHMJGBZCHFUXBBPIEBBEFDWOMXXEPOMDGSMPIUZOMRZQNSJAVNATGIWPDFISKFQXJNVFXPHOZDAEZFDAHDXXQKZMGNSGKQNWGNGJGJZVVITKNFLVCPMZSDMCHBTVAWYVZLIXXIADXNYILEYNIQHKMOGMVOCWGHCWIYMPEPADSJAAKEGTUSEDWAHMNYJDIHBKHVUHLYGNGZDBULRXLSAJHPCMNWCEAAPYMHDTYWPADOTJTXTXUKLCHWKUSZRHEKQEFPVJEJJHRWCKYOIWALRTIBUMNOCRXLSIKQCJVQXEPGOHRUDJDKMUUUDORURWXJNVRVMNOUNRFKSVMTMZGOIJLXEPAMVGESOADYIGZXRBJDIWKNOWTCSROAQTBECHTOZVSQUOOJRZIBAUHMKAXDCIMDZJFMABGRNTGPUJAUNFPFWCJG
 6 2
ABCABC
 41 19
TMEYYIIELFDCMBDKWWKYNRNDUPRONYROXQCLVQALP
 5 2
ABACA
 377 3
EADADBBBBDEAABBAEBABACDBDBBCACAADBEAEACDEAABACADEEDEACACDADABBBBDDEECBDABACACBAECBADAEBDEEBDBCDAEADBCDDACACDCCEEDBCCBBCEDBECBABCDDBBDEADEDAEACDECECBEBACBCCDCDBDAECDECADBCBEDBBDAAEBCAAECCDCCDBDDEBADEEBDCAEABBDEDBBDDEAECCBDDCDEACDAECCBDDABABEAEDCDEDBAECBDEACEBCECEACDCBABCBAAEAADACADBBBBABEADBCADEBCBECCABBDDDEEBCDEBADEBDAAABBEABADEDEAEABCEEBEEDEAEBEABCEDDBACBCCADEBAAAAAEABABBCE
 3 26
AAB
 27 1
ABCDEFGHIJKLMNOPQRSTUVWXYZA
 73 2
DEBECECBBADAADEAABEAEEEAEBEAEBCDDBABBAEBACCBEEBBAEADEECACEDEEDABACDCDBBBD
 7 2
ABCDBCD
 5 1
AZAZA
 44 15
HGJIFCGGCDGIJDHBIBGAEABCIABIGBDEADBBBAGDFDHA
 5 2
ABCAB
 8 3
ABCBCDCA
 26 1
ABCDEFGHIJKLMNOPQRSTUVWXYZ

YES
 YES
 NO
 NO
 YES
 NO
 YES
 YES
 YES
 YES
 NO
 YES
 NO
 NO


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Collections;
import java.util.StringTokenizer;

public class B {
	static class Pair {
		int s;
		int e;

		Pair(int s, int e) {
			this.s = s;
			this.e = e;
		}
	}

	public static void main(String[] args) {
		FastScanner sc = new FastScanner();
		int t = 1;
		// t = sc.nextInt();
		while (t-- > 0) {
			int n = sc.nextInt();
			int k = sc.nextInt();
			char[] s = sc.next().toCharArray();
			if (k == 26) {
				System.out.println("NO");
				continue;
			}
			solve(s, k, n);
		}
	}

	private static void solve(char[] s, int k, int n) {
		Pair[] alpha = new Pair[26];
		for (int i = 0; i < alpha.length; i++) {
			alpha[i] = new Pair(Integer.MAX_VALUE, Integer.MIN_VALUE);
		}
		for (int i = 0; i < s.length; i++) {
			int idx = s[i] - 'A';
			Pair p = alpha[idx];
			if (i < p.s) {
				p.s = i;
			}
			if (i > p.e) {
				p.e = i;
			}
		}
		boolean[] vis = new boolean[26];
		/*
		 * 8 3 ABCBCDCA
		 */
		for (int i = 0; i < s.length; i++) {
			Pair p = alpha[s[i] - 'A'];
			if (p.s == p.e) {
				if (k == 0) {
					System.out.println("YES");
					return;
				}
			} else {
				if (p.e == i) {
					vis[s[i] - 'A'] = false;
					k++;
				} else {
					if (!vis[s[i] - 'A']) {
						vis[s[i] - 'A'] = true;
						k--;
					}

				}
			}
			if (k < 0) {
				System.out.println("YES");
				return;
			}
		}
		System.out.println("NO");
//		int K = k;
//		for (int i = 0; i < alpha.length; i++) {
//			k = K;
//			Pair p1 = alpha[i];
//			if (p1.s == Integer.MAX_VALUE || p1.e == Integer.MIN_VALUE) {
//				continue;
//			}
//			for (int j = 0; j < alpha.length; j++) {
//				if (i == j) {
//					continue;
//				}
//				Pair p2 = alpha[j];
//				if (p2.s == Integer.MAX_VALUE || p2.e == Integer.MIN_VALUE) {
//					continue;
//				}
//				if (p2.s < p1.e && p1.s < p2.s) {
//					k--;
//					if (p2.s == p2.e) {
//						if (k == 0) {
//							break;
//						}
//						k++;
//					}
//				}
//			}
//			if (k <= 0) {
//				System.out.println("YES");
//				return;
//			}
//		}
//		System.out.println("NO");
	}

	static void sort(int[] a) {
		ArrayList<Integer> l = new ArrayList<>();
		for (int i : a)
			l.add(i);
		Collections.sort(l);
		for (int i = 0; i < a.length; i++)
			a[i] = l.get(i);
	}

	static class FastScanner {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st = new StringTokenizer("");

		String next() {
			while (!st.hasMoreTokens())
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}

		int nextInt() {
			return Integer.parseInt(next());
		}

		int[] readArray(int n) {
			int[] a = new int[n];
			for (int i = 0; i < n; i++)
				a[i] = nextInt();
			return a;
		}

		long nextLong() {
			return Long.parseLong(next());
		}
	}

}
