




from datetime import datetime

import requests
from bsa import BeautifulSoup

if __name__ == "__main__":
  __lowerCAmelCase	:       Optional[Any]     =	input('Enter image url: ').strip()
  print(F'''Downloading image from {url} ...''')
  __lowerCAmelCase	:       str     =	BeautifulSoup(requests.get(url).content, 'html.parser')
  # The image URL is in the content field of the first meta tag with property og:image
  __lowerCAmelCase	:       List[Any]     =	soup.find('meta', {'property': 'og:image'})['content']
  __lowerCAmelCase	:       Dict     =	requests.get(image_url).content
  __lowerCAmelCase	:       int     =	F'''{datetime.now():%Y-%m-%d_%H:%M:%S}.jpg'''
  with open(file_name, 'wb') as fp:
    fp.write(image_data)
  print(F'''Done. Image saved to disk as {file_name}.''')












def     __magic_name__       (				A	:      int,						A	:      int,						A	:      int     ):






			'''simple docstring'''







			if exponent == 1:
						return base
			if exponent % 2 == 0:
						a					=    _modexpt(A,						exponent // 2,						A     ) % modulo_value
						return (x * x) % modulo_value
			else:
						return (base * _modexpt(A,						exponent - 1,						A     )) % modulo_value




def     __magic_name__       (				A	:      int = 1777,						A	:      int = 1855,						A	:      int = 8     ):






			'''simple docstring'''







			a					=    base
			for _ in range(1,						A     ):
						a					=    _modexpt(A,						A,						10**digits     )

			return result


if __name__ == "__main__":
		print(F'''{solution() = }''')






