input: Write a function to scrape photos and captions from a given website and return a list of dictionaries where each dictionary contains a photo URL and its corresponding caption. If there is no caption available, include the string 'No caption' for that photo. The function should take a single argument representing the URL of the website.
  
  def scrape_photos_and_captions(url):
      from bs4 import BeautifulSoup
      import requests
  
      req = requests.get(url)
      html = req.text
      soup = BeautifulSoup(html, features='lxml')
      image_divs = soup.find_all('div', {'class': 'image-gallery__image'})
  
      photos_and_captions = []
      for image_div in image_divs:
          figure = image_div.find('figure')
          src = figure.find('img')['src']
          caption = figure.find('figcaption')
          caption_text = caption.text if caption else 'No caption'
          photos_and_captions.append({'photo': src, 'caption': caption_text})
  
      return photos_and_captions
  
  assert scrape_photos_and_captions('https://example.com/webpage_with_captions')==[{'photo': 'https://example.com/image1.jpg', 'caption': 'First photo caption'}, {'photo': 'https://example.com/image2.jpg', 'caption': 'Second photo caption'}]
  assert scrape_photos_and_captions('https://example.com/webpage_missing_captions')==[{'photo': 'https://example.com/image3.jpg', 'caption': 'No caption'}, {'photo': 'https://example.com/image4.jpg', 'caption': 'No caption'}]
  assert scrape_photos_and_captions('https://example.com/webpage_empty')==[]
output: def scrape_photos_and_captions(url):
      from bs4 import BeautifulSoup
      import requests
  
      req = requests.get(url)
      html = req.text
      soup = BeautifulSoup(html, features='lxml')
      image_divs = soup.find_all('div', {'class': 'image-gallery__image'})
  
      photos_and_captions = []
      for image_div in image_divs:
          figure = image_div.find('figure')
          src = figure.find('img')['src']
          caption = figure.find('figcaption')
          caption_text = caption.text if caption else 'No caption'
          photos_and_captions.append({'photo': src, 'caption': caption_text})
  
      return photos_and_captions