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.util.*;
import java.io.*;
public class FestiveEvening 
{
	static boolean solution(int n,int k,String s)
	{
		HashSet<Character> hs=new HashSet<Character>();
		for(int i=0;i<s.length();i++)
			hs.add(s.charAt(i));
		Iterator<Character> it=hs.iterator();
		HashSet<Integer> start_index=new HashSet<Integer>();
		HashSet<Integer> end_index=new HashSet<Integer>();
		while(it.hasNext())
		{
			char c=it.next();
			int start=s.indexOf(c);
			int end=s.lastIndexOf(c);
			
			start_index.add(start);
			end_index.add(end);
		}
		int gates_open=0;
		for(int i=0;i<n;i++)
		{
			if(start_index.contains(i))
				gates_open++;
			if(gates_open>k)
				return true;

			if(end_index.contains(i))
				gates_open--;
			}
		return false;
	}
	
	public static void main(String[] args) 
	{
		// TODO Auto-generated method stub
		FastReader hk=new FastReader();
		int n=hk.nextInt();
		int k=hk.nextInt();
		String s=hk.next();
		if(solution(n,k,s))
			System.out.println("YES");
		else
			System.out.println("NO");
	}
	//input class
	//class to take input
	static class FastReader
	{
		BufferedReader br;
		StringTokenizer st;
		 
		public FastReader()
		{
		    br = new BufferedReader(new
		             InputStreamReader(System.in));
		}
		 
		String next()
		{
		    while (st == null || !st.hasMoreElements())
		    {
		        try
		        {
		            st = new StringTokenizer(br.readLine());
		        }
		        catch (IOException  e)
		        {
		            e.printStackTrace();
		        }
		    }
		    return st.nextToken();
		}
		 
		int nextInt()
		{
		    return Integer.parseInt(next());
		}
		 
		long nextLong()
		{
		    return Long.parseLong(next());
		}
		 
		double nextDouble()
		{
		    return Double.parseDouble(next());
		}
		 
		String nextLine()
		{
		    String str = "";
		    try
		    {
		        str = br.readLine();
		    }
		    catch (IOException e)
		    {
		        e.printStackTrace();
		    }
		    return str;
		}
		}

}