input: Write a function to convert an HTML string to plain text without using any libraries. The function should remove all HTML tags and return the remaining text. If the input string is empty, return an empty string.
  assert html_to_text('<p>Hello, World!</p>')=='Hello, World!'
  assert html_to_text('<h1>Title</h1><p>Paragraph</p>')=='TitleParagraph'
  assert html_to_text('')==''
  assert html_to_text('<br><br>')==''
  assert html_to_text('This is <b>bold</b> text.')=='This is bold text.'
output: def html_to_text(html):
      if not html:
          return ''
      text = ''
      inside_tag = False
      for char in html:
          if char == '<':
              inside_tag = True
          elif char == '>':
              inside_tag = False
          elif not inside_tag:
              text += char
      return text