• + 0 comments

    Simple Python Code:

    def equalizeArray(arr):
        a=max(set(arr),key= arr.count)    
        count=0
        for i in arr:
            if i != a:
                count+=1
        return count