


import numpy as np





def 	_lowerCAmelCase       (    _lowerCAmelCase )						->	np.array:


						'''simple docstring'''






						return 1 / (1 + np.exp(-vector ))


if __name__ == "__main__":
	import doctest

	doctest.testmod()









def 	_lowerCAmelCase       (    _lowerCAmelCase )						->	int:


						'''simple docstring'''






						__snake_case				=		abs(_lowerCAmelCase )
						__snake_case				=		0
						while n > 0:
												res += n % 10
												n //= 10
						return res





def 	_lowerCAmelCase       (    _lowerCAmelCase )						->	int:


						'''simple docstring'''






						__snake_case				=		abs(_lowerCAmelCase )
						return n if n < 10 else n % 10 + sum_of_digits(n // 10 )





def 	_lowerCAmelCase       (    _lowerCAmelCase )						->	int:


						'''simple docstring'''






						return sum(int(_lowerCAmelCase ) for c in str(abs(_lowerCAmelCase ) ) )





def 	_lowerCAmelCase       (    )						->	None:


						'''simple docstring'''






						from collections.abc import Callable
						from timeit import timeit

						def benchmark_a_function(_lowerCAmelCase      ,	_lowerCAmelCase ) -> None:
												__snake_case				=		F'''{func.__name__}({value})'''
												__snake_case				=		timeit(F'''__main__.{call}'''      ,	setup="import __main__" )
												print(F'''{call:56} = {func(_lowerCAmelCase )} -- {timing:.4f} seconds''' )

						for value in (26_2144, 1125_8999_0684_2624, 126_7650_6002_2822_9401_4967_0320_5376):
												for func in (sum_of_digits, sum_of_digits_recursion, sum_of_digits_compact):
																		benchmark_a_function(_lowerCAmelCase      ,	_lowerCAmelCase )
												print()


if __name__ == "__main__":
	import doctest

	doctest.testmod()
	benchmark()





