def MaximinWinner(profile):
    """
    Returns an integer that represents the winning candidate given an election profile.
    Tie-breaking rule: numerically increasing order

    :ivar Profile profile: A Profile object that represents an election profile.
    """

    # Currently, we expect the profile to contain complete ordering over candidates.
    elecType = profile.getElecType()
    if elecType != "soc" and elecType != "toc":
        print("ERROR: unsupported profile type")
        exit()

    maximinscores = getMaximinScores(profile)
    winner = max(maximinscores.items(), key=lambda x: x[1])[0]
    return winner
Returns an integer that represents the winning candidate given an election profile.
    Tie-breaking rule: numerically increasing order

    :ivar Profile profile: A Profile object that represents an election profile.