<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def random_card(cards, remove=False):
 """ Returns a random card from the Stack. If ``remove=True``, it will also remove the card from the deck. :arg bool remove: Whether or not to remove the card from the deck. :returns: A random Card object, from the Stack. """

    if not remove:
        return random.choice(cards)
    else:
        i = random.randrange(len(cards))
        card = cards[i]
        del cards[i]
        return card