input: 
  def html_to_text(html_string: str) -> str:
      """ Converts an HTML string to plain text by removing all HTML tags.
      >>> html_to_text('<p>Hello, <b>world</b>!</p>')
      'Hello, world!'
      >>> html_to_text('<html><body><h1>Title</h1><p>This is a paragraph.</p></body></html>')
      'TitleThis is a paragraph.'
      """
      output = ''
      in_tag = False
      for char in html_string:
          if char == '<':
              in_tag = True
          elif char == '>':
              in_tag = False
          elif in_tag == False:
              output += char
      return output
  
output:     output = ''
      in_tag = False
      for char in html_string:
          if char == '<':
              in_tag = True
          elif char == '>':
              in_tag = False
          elif in_tag == False:
              output += char
      return output