



from __future__ import annotations

from collections.abc import Callable







def    lowerCAmelCase_  (lowerCAmelCase__:		Callable[[int | float], int | float]		,	lowerCAmelCase__:		int | float		,	lowerCAmelCase__:		int | float		,	lowerCAmelCase__:		int = 1_0_0		,	):





			"""simple docstring"""


			UpperCAmelCase_:		List[Any]       			=    x_start
			UpperCAmelCase_:		Tuple       			=    fnc(lowerCAmelCase__     )
			UpperCAmelCase_:		str       			=    0.0

			for _ in range(lowerCAmelCase__     ):
						# Approximates small segments of curve as linear and solve
						# for trapezoidal area
						UpperCAmelCase_:		Any       			=    (x_end - x_start) / steps + xa
						UpperCAmelCase_:		Dict       			=    fnc(lowerCAmelCase__     )
						area += abs(fxa + fxa     ) * (xa - xa) / 2

						# Increment step
						UpperCAmelCase_:		str       			=    xa
						UpperCAmelCase_:		Any       			=    fxa
			return area


if __name__ == "__main__":







	def    lowerCAmelCase_  (lowerCAmelCase__:		List[Any]     ):





				"""simple docstring"""


				return x**3

	print('f(x) = x^3')
	print('The area between the curve, x = -10, x = 10 and the x axis is:')
	a			:     Dict     = 10
	while i <= 100_000:
		a			:     Optional[Any]     = trapezoidal_area(f, -5, 5, i)
		print(F'''with {i} steps: {area}''')
		i *= 10











import decimal







def    lowerCAmelCase_  ():





			"""simple docstring"""


			UpperCAmelCase_:		Union[str, Any]       			=    0
			UpperCAmelCase_:		Optional[Any]       			=    decimal.Context(prec=1_0_5     )
			for i in range(2		,	1_0_0     ):
						UpperCAmelCase_:		str       			=    decimal.Decimal(lowerCAmelCase__     )
						UpperCAmelCase_:		Any       			=    number.sqrt(lowerCAmelCase__     )
						if len(str(lowerCAmelCase__     )     ) > 1:
									answer += int(str(lowerCAmelCase__     )[0]     )
									UpperCAmelCase_:		str       			=    str(lowerCAmelCase__     )[2:1_0_1]
									answer += sum(int(lowerCAmelCase__     ) for x in sqrt_number_str     )
			return answer


if __name__ == "__main__":
	import doctest

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






