Driver code
public static void Main ( ) { string str1 = " anagram " ; string str2 = " grammar " ; int k = 2 ; if ( arekAnagrams ( str1 , str2 , k ) ) Console . Write ( " Yes " ) ; else Console . Write ( " No " ) ; } }