input: Write a python function to extract post titles from a given URL.
  assert extract_post_titles('https://example.com') == ['Example Title 1', 'Example Title 2', 'Example Title 3']
  assert extract_post_titles('https://anotherexample.com') == ['Another Example Title 1', 'Another Example Title 2']
  assert extract_post_titles('https://yetanotherexample.com') == ['Yet Another Example Title 1', 'Yet Another Example Title 2', 'Yet Another Example Title 3']
output: def extract_post_titles(url):
      import requests
      from bs4 import BeautifulSoup
  
      response = requests.get(url)
      soup = BeautifulSoup(response.content, 'html.parser')
      titles = []
  
      for title in soup.find_all('h2', class_='post-title'):
          titles.append(title.get_text().strip())
  
      return titles