def yes_or_no(question):
    """Asks a yes or no question, and captures input.  Blank input is interpreted as Y."""
    reply = str(input(question+' (Y/n): ')).capitalize().strip()

    if reply == "": #pylint: disable=no-else-return
        return True
    elif reply[0] == 'Y':
        return True
    elif reply[0] == 'N':
        return False

    return yes_or_no("Please enter Y or N.")