summaryrefslogtreecommitdiff
path: root/progs/a713.py
blob: 772766f1bd6dd8c33ddb59d0a62002b6b6449340 (plain)
1
2
3
4
5
6
7
8
9
10
def minimum_Length(s) : 
    maxOcc = 0
    n = len(s) 
    arr = [0]*26
    for i in range(n) : 
        arr[ord(s[i]) -ord('a')] += 1
    for i in range(26) : 
        if arr[i] > maxOcc : 
            maxOcc = arr[i] 
    return n - maxOcc