input: Write a python function to fetch and print news headlines from a given URL.
  assert fetch_headlines('https://www.example.com/news')==['Headline 1', 'Headline 2', 'Headline 3']
  assert fetch_headlines('https://www.example.com/anothernews')==['Another Headline 1', 'Another Headline 2']
  assert fetch_headlines('https://www.example.com/morenews')==['More News 1', 'More News 2', 'More News 3']
output: def fetch_headlines(url):
      import requests
      from bs4 import BeautifulSoup
      
      response = requests.get(url)
      soup = BeautifulSoup(response.content, 'html.parser')
      
      headlines = []
      for item in soup.find_all('h1', class_='headline'):
          headlines.append(item.get_text(strip=True))
      
      return headlines