input: from typing import List
  
  def scrape_headlines(url: str) -> List[str]:
      """ Scrape the headlines from an online news website given its URL.
      >>> scrape_headlines("https://www.news.com/")
      ['First Headline', 'Second Headline', 'Third Headline']
      """
      import requests
      from bs4 import BeautifulSoup
      
      # get the response in the form of html
      r = requests.get(url)
      
      # create a beautifulsoup object to parse contents
      soup = BeautifulSoup(r.content, 'html5lib')
      
      # find headlines from the parsed page
      headlines = soup.find_all('h2')
      
      # return the headlines as a list of strings
      return [headline.text for headline in headlines]
output:     import requests
      from bs4 import BeautifulSoup
      
      # get the response in the form of html
      r = requests.get(url)
      
      # create a beautifulsoup object to parse contents
      soup = BeautifulSoup(r.content, 'html5lib')
      
      # find headlines from the parsed page
      headlines = soup.find_all('h2')
      
      # return the headlines as a list of strings
      return [headline.text for headline in headlines]