




from __future__ import annotations




def 			__magic_name__				( A		:					list[int | float],  A		:					int,  A		:					int   ):






			'''simple docstring'''







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







			'''simple docstring'''

			if length <= 0 or not isinstance(UpperCamelCase__			,			UpperCamelCase__ ):
						raise ValueError('''Length must be a positive integer.''' )
			return [n * (2 * n - 1) for n in range(UpperCamelCase__ )]


if __name__ == "__main__":
				print(hexagonal_numbers(length=5))
				print(hexagonal_numbers(length=10))



