


'''simple docstring'''



import requests
from bsa import BeautifulSoup


def    lowerCamelCase__   ( A     :    str = "AAPL"  ):




						'''simple docstring'''






						UpperCAmelCase         =			f"""https://in.finance.yahoo.com/quote/{symbol}?s={symbol}"""
						UpperCAmelCase         =			BeautifulSoup(requests.get(A  ).text   ,     '''html.parser'''  )
						UpperCAmelCase         =			'''My(6px) Pos(r) smartphone_Mt(6px)'''
						return soup.find('''div'''   ,     class_=class_  ).find('''span'''  ).text


if __name__ == "__main__":
	for symbol in "AAPL AMZN IBM GOOG MSFT ORCL".split():
		print(F"""Current {symbol:<4} stock price is {stock_price(symbol):>8}""")





'''simple docstring'''



import functools


def    lowerCamelCase__   ( A     :    list[int]   ,     A     :    list[int]  ):




						'''simple docstring'''






						if not isinstance(A   ,     A  ) or not all(isinstance(A   ,     A  ) for day in days  ):
												raise ValueError('''The parameter days should be a list of integers'''  )

						if len(A  ) != 3 or not all(isinstance(A   ,     A  ) for cost in costs  ):
												raise ValueError('''The parameter costs should be a list of three integers'''  )

						if len(A  ) == 0:
												return 0

						if min(A  ) <= 0:
												raise ValueError('''All days elements should be greater than 0'''  )

						if max(A  ) >= 3_66:
												raise ValueError('''All days elements should be less than 366'''  )

						UpperCAmelCase         =			set(A  )

						@functools.cache
						def dynamic_programming(A     :    int  ) -> int:
												if index > 3_65:
																		return 0

												if index not in days_set:
																		return dynamic_programming(index + 1  )

												return min(
												    costs[0] + dynamic_programming(index + 1  )   ,     costs[1] + dynamic_programming(index + 7  )   ,     costs[2] + dynamic_programming(index + 30  )   ,     )

						return dynamic_programming(1  )


if __name__ == "__main__":
	import doctest

	doctest.testmod()





