<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _GetUserTypeAndPassword(username, password=None, is_admin=False):
 """Returns the user-type and password for a user. Args: username: Username for the user. password: Password for the user. If None, or not provided, we will prompt for one via the terminal. is_admin: Indicates whether the user should have admin privileges. """

  if is_admin:
    user_type = api_user.ApiGrrUser.UserType.USER_TYPE_ADMIN
  else:
    user_type = api_user.ApiGrrUser.UserType.USER_TYPE_STANDARD
  if password is None:
    # TODO
    # pytype: disable=wrong-arg-types
    password = getpass.getpass(prompt="Please enter password for user '%s':" %
                               username)
    # pytype: enable=wrong-arg-types
  return user_type, password