__lowercase							 =					[sum(int(c, 10) ** 2 for c in i.__str__()) for i in range(10_0000)]



def lowerCamelCase  (   SCREAMING_SNAKE_CASE	):
    '''simple docstring'''







    __UpperCamelCase     :Tuple			  =		0
    while number:
        # Increased Speed Slightly by checking every 5 digits together.
        sum_of_digits_squared += DIGITS_SQUARED[number % 100_000]
        number //= 100_000

    return sum_of_digits_squared


# There are 2 Chains made,
# One ends with 89 with the chain member 58 being the one which when declared first,
# there will be the least number of iterations for all the members to be checked.

# The other one ends with 1 and has only one element 1.

# So 58 and 1 are chosen to be declared at the starting.

# Changed dictionary to an array to quicken the solution
__lowercase							 =					[None] * 1000_0000
__lowercase							 =					True
__lowercase							 =					False



def lowerCamelCase  (   SCREAMING_SNAKE_CASE	):
    '''simple docstring'''







    if CHAINS[number - 1] is not None:
        return CHAINS[number - 1]  # type: ignore

    __UpperCamelCase     :Optional[Any]			  =		chain(next_number(SCREAMING_SNAKE_CASE	)	)
    __UpperCamelCase     :Union[str, Any]			  =		number_chain

    while number < 10_000_000:
        __UpperCamelCase     :List[Any]			  =		number_chain
        number *= 10

    return number_chain



def lowerCamelCase  (   SCREAMING_SNAKE_CASE = 10_000_000	):
    '''simple docstring'''







    for i in range(1  ,			SCREAMING_SNAKE_CASE	):
        if CHAINS[i] is None:
            chain(i + 1	)

    return CHAINS[:number].count(SCREAMING_SNAKE_CASE	)


if __name__ == "__main__":
    import doctest

    doctest.testmod()
    print(F'{solution() = }')






from datetime import datetime

import requests
from bsa import BeautifulSoup

if __name__ == "__main__":
   __lowerCamelCase			: str							   =		input('''Enter image url: ''').strip()
   print(F"""Downloading image from {url} ...""")
   __lowerCamelCase			: Any							   =		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			: Tuple							   =		requests.get(image_url).content
   __lowerCamelCase			: Union[str, Any]							   =		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}.""")
