def valid_input(prompt, options):
    """Validates user input, repeats the prompt on invalid valid_input.

    Args:
        prompt: A str representing the prompt a player sees
        options: A list of strs representing the allowed inputs

    Returns:
        response: A str representing the players choice
    """
    while True:
        response = input(prompt)
        if response in options:
            return response