def cardValue(card):
    """Returns the value of a given card."""
    if card[0] >= '2' and card[0] <= '9':
        return int(card[0])
    elif card[0] == 'T':
        return 10
    elif card[0] == 'J':
        return 11
    elif card[0] == 'Q':
        return 12
    elif card[0] == 'K':
        return 13
    elif card[0] == 'A':
        return 14