input: Write a python function to extract and print all the headlines (h2 tags) from a given URL using BeautifulSoup.
  assert extract_headlines("http://example.com/") == ["Headline 1", "Headline 2", "Headline 3"]
  assert extract_headlines("http://example.org/") == ["Example Headline 1", "Example Headline 2"]
  assert extract_headlines("http://example.net/") == ["News Headline 1", "News Headline 2", "News Headline 3"]
output: def extract_headlines(url):
      import requests
      from bs4 import BeautifulSoup
  
      response = requests.get(url)
      soup = BeautifulSoup(response.content, 'html.parser')
  
      headlines = [h2.get_text(strip=True) for h2 in soup.find_all('h2')]
      return headlines