import random def dice_roll(): return random.randint(1, 6) def coin_flip(): if random.randint(1, 2) == 1: return 'heads' else: return 'tails'