
'''simple docstring'''



from __future__ import annotations


def A (__lowerCamelCase :list[int | float]					,      __lowerCamelCase :int					,      __lowerCamelCase :int						):
						if len(__lowerCamelCase						) == 0:
												raise ValueError("""find_max() arg is an empty sequence"""						)
						if (
						    left >= len(__lowerCamelCase						)
						    or left < -len(__lowerCamelCase						)
						    or right >= len(__lowerCamelCase						)
						    or right < -len(__lowerCamelCase						)
						):
												raise IndexError("""list index out of range"""						)
						if left == right:
												return nums[left]
						_lowerCAmelCase    		=					(left + right) >> 1  # the middle
						_lowerCAmelCase    		=					find_max(__lowerCamelCase					,      __lowerCamelCase					,      __lowerCamelCase						)  # find max in range[left, mid]
						_lowerCAmelCase    		=					find_max(__lowerCamelCase					,      mid + 1					,      __lowerCamelCase						)  # find max in range[mid + 1, right]

						return left_max if left_max >= right_max else right_max


if __name__ == "__main__":
						import doctest

						doctest.testmod(verbose=True)





def A    (							__UpperCamelCase			,						__UpperCamelCase			,						__UpperCamelCase       )    ->   int:

			if exponent == 1:
						return base
			if exponent % 2 == 0:
						A__	  =     _modexpt(__UpperCamelCase			,						exponent // 2			,						__UpperCamelCase       ) % modulo_value
						return (x * x) % modulo_value
			else:
						return (base * _modexpt(__UpperCamelCase			,						exponent - 1			,						__UpperCamelCase       )) % modulo_value


def A    (							__UpperCamelCase = 1_777			,						__UpperCamelCase = 1_855			,						__UpperCamelCase = 8       )    ->   int:
			A__	  =     base
			for _ in range(1			,						__UpperCamelCase       ):
						A__	  =     _modexpt(__UpperCamelCase			,						__UpperCamelCase			,						10**digits       )

			return result


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




