



from collections.abc import Callable

import numpy as np






def  lowerCamelCase_	(      lowerCAmelCase__	:	Callable			,	lowerCAmelCase__	:	float			,	lowerCAmelCase__	:	float			,	lowerCAmelCase__	:	float			,	lowerCAmelCase__	:	float				)       ->							np.array:

							'''simple docstring'''






							A      						=    int(np.ceil((x_end - xa) / step_size				)				)
							A      						=    np.zeros((n + 1,)				)
							A      						=    ya
							A      						=    xa

							for k in range(lowerCAmelCase__				):
														A      						=    y[k] + step_size * ode_func(lowerCAmelCase__			,	y[k]				)
														A      						=    y[k] + (
														    (step_size / 2) * (ode_func(lowerCAmelCase__			,	y[k]				) + ode_func(x + step_size			,	lowerCAmelCase__				))
														)
														x += step_size

							return y


if __name__ == "__main__":
				import doctest

				doctest.testmod()







from collections.abc import Sequence
def 		lowercase__  (				_UpperCamelCase       ,							_UpperCamelCase) ->			float:
      """simple docstring"""

      return sum(c * (x**i) for i, c in enumerate(_UpperCamelCase))
def 		lowercase__  (				_UpperCamelCase       ,							_UpperCamelCase) ->			float:
      """simple docstring"""

      UpperCamelCase					       =  0.0
      for coeff in reversed(_UpperCamelCase):
            UpperCamelCase					       =  result * x + coeff
      return result


if __name__ == "__main__":
       __magic_name__   :  Union[str, Any]        =							(0.0, 0.0, 5.0, 9.3, 7.0)
       __magic_name__   :  List[str]        =							10.0
       print(evaluate_poly(poly, x))
       print(horner(poly, x))



