Function to find the minimum number of deletions required to make the occurrences of the given character K continuous
def noOfDeletions ( string , k ) : NEW_LINE INDENT ans = 0 ; cnt = 0 ; pos = 0 ; NEW_LINE DEDENT