(
        question: Text, input_type: Callable[[Text], Any],
        default: Optional[Any] = None,
        hide_input: Optional[bool] = False)
return input_type(answer)
Presents the user with a prompt with a default return value and a type.

    Args:
        question (str): the text that the user will be prompted.
        input_type (type): the type of the input data.
        default (object): default value for the question, optional.
        hide_input (bool): whether the input should be hidden, eg. when asking
            for a password.

    Returns:
        object: The value (type of input_type) that is ready by the user.
Presents the user with a prompt with a default return value and a type.
Presents the user with a prompt with a default return value and a type .
def ask_question(
        question: Text, input_type: Callable[[Text], Any],
        default: Optional[Any] = None,
        hide_input: Optional[bool] = False) -> Any:
    """Presents the user with a prompt with a default return value and a type.

    Args:
        question (str): the text that the user will be prompted.
        input_type (type): the type of the input data.
        default (object): default value for the question, optional.
        hide_input (bool): whether the input should be hidden, eg. when asking
            for a password.

    Returns:
        object: The value (type of input_type) that is ready by the user.
    """
    if hide_input:
        if default:
            hint = '**'
        else:
            hint = ''

        return getpass.getpass(f'{question} [{hint}] ')

    if default:
        ask = f'{question} [{default}]'
    else:
        ask = question

    answer = input(f'{ask}: ')
    return input_type(answer)
def ask_question ( question : Text , input_type : Callable [ [ Text ] , Any ] , default : Optional [ Any ] = None , hide_input : Optional [ bool ] = False ) -> Any : if hide_input : if default : hint = '**' else : hint = '' return getpass . getpass ( f'{question} [{hint}] ' ) if default : ask = f'{question} [{default}]' else : ask = question answer = input ( f'{ask}: ' ) return input_type ( answer )