





def        __SCREAMING_SNAKE_CASE	(				__lowercase:		int = 10_00):



  '''simple docstring'''






  __lowerCAmelCase								=					0
  __lowerCAmelCase								=					(n - 1) // 3
  total += ((terms) * (6 + (terms - 1) * 3)) // 2  # total of an A.P.
  __lowerCAmelCase								=					(n - 1) // 5
  total += ((terms) * (10 + (terms - 1) * 5)) // 2
  __lowerCAmelCase								=					(n - 1) // 15
  total -= ((terms) * (30 + (terms - 1) * 15)) // 2
  return total


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




_A		:					Union[str, Any]          =							1_000



def      __lowerCAmelCase    (				snake_case						:     float			)							->				float:
   return x * x



def      __lowerCAmelCase    (				snake_case						:     Optional[int]    ,   snake_case						:     float    ,   snake_case						:     float    ,   snake_case						:     int = 4			)							->				float:
   assert callable(
       snake_case			), f'the function(object) passed should be callable your input : {function}'
   assert isinstance(snake_case    ,   (float, int)			), f'a should be float or integer your input : {a}'
   assert isinstance(function(snake_case			)    ,   (float, int)			), (
       "the function should return integer or float return type of your function, "
       f'{type(snake_case			)}'
   )
   assert isinstance(snake_case    ,   (float, int)			), f'b should be float or integer your input : {b}'
   assert (
       isinstance(snake_case    ,   snake_case			) and precision > 0
   ), f'precision should be positive integer your input : {precision}'

   # just applying the formula of simpson for approximate integration written in
   # mentioned article in first comment of this file and above this function

   __lowerCamelCase:					List[str]	 =						(b - a) / N_STEPS
   __lowerCamelCase:					Optional[Any]	 =						function(snake_case			) + function(snake_case			)

   for i in range(1    ,   snake_case			):
      __lowerCamelCase:					Dict	 =						a + h * i
      result += function(snake_case			) * (4 if i % 2 else 2)

   result *= h / 3
   return round(snake_case    ,   snake_case			)


if __name__ == "__main__":
   import doctest

   doctest.testmod()


