def equalizer(n: int, m: int, total: int):
    """
    Receives total, m and n [0..total]
    Returns a tuple (a, b) so that their sum -> total, and a / b -> 1
    """
    oddity = total % 2
    smallest = min(n, m, total // 2 + oddity)
    if smallest == n:
        return (n, min(m, total-n))
    elif smallest == m:
        return (min(n, total-m), m)
    else:
        return (total // 2, total // 2 + oddity)