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.

def CopelandWinner(profile, alpha=0.5):
    """
    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()

    copelandscores = getCopelandScores(profile, alpha)
    winner = max(copelandscores.items(), key=lambda x: x[1])[0]
    return winner