



"""simple docstring"""






from __future__ import annotations

class 			__SCREAMING_SNAKE_CASE      :


					'''simple docstring'''





					def __init__(			self				:    Dict,    lowerCamelCase				:    int = 0	)->   None:
								lowerCamelCase__						:						Union[str, Any]						      =value
								lowerCamelCase__						:						Node | None						      =None
								lowerCamelCase__						:						Node | None						      =None






def 	snake_case__  (						__lowerCamelCase							:       Node | None				,						__lowerCamelCase							:       Node | None      ):
			"""simple docstring"""
			if treea is None:
						return treea
			if treea is None:
						return treea

			lowerCamelCase__						:						Optional[Any]						      =treea.value + treea.value
			lowerCamelCase__						:						Optional[int]						      =merge_two_binary_trees(treea.left				,						treea.left      )
			lowerCamelCase__						:						Dict						      =merge_two_binary_trees(treea.right				,						treea.right      )
			return treea






def 	snake_case__  (						__lowerCamelCase							:       Node | None      ):
			"""simple docstring"""
			if root:
						print(root.value      )
						print_preorder(root.left      )
						print_preorder(root.right      )


if __name__ == "__main__":
		_lowercase					:					int 		=		Node(1)
		_lowercase					:					Union[str, Any] 		=		Node(2)
		_lowercase					:					List[Any] 		=		Node(3)
		_lowercase					:					Tuple 		=		Node(4)

		_lowercase					:					Optional[Any] 		=		Node(2)
		_lowercase					:					int 		=		Node(4)
		_lowercase					:					List[Any] 		=		Node(6)
		_lowercase					:					Any 		=		Node(9)
		_lowercase					:					Optional[Any] 		=		Node(5)

		print("Tree1 is: ")
		print_preorder(treea)
		print("Tree2 is: ")
		print_preorder(treea)
		_lowercase					:					Tuple 		=		merge_two_binary_trees(treea, treea)
		print("Merged Tree is: ")
		print_preorder(merged_tree)









"""simple docstring"""






def 	snake_case__  (						__lowerCamelCase							:       int = 998001      ):
			"""simple docstring"""

			# fetches the next number
			for number in range(n - 1				,						9999				,						-1      ):
						lowerCamelCase__						:						Optional[int]						      =str(__lowerCamelCase      )

						# checks whether 'str_number' is a palindrome.
						if str_number == str_number[::-1]:
									lowerCamelCase__						:						Optional[int]						      =999

									# if 'number' is a product of two 3-digit numbers
									# then number is the answer otherwise fetch next number.
									while divisor != 99:
												if (number % divisor == 0) and (len(str(number // divisor      )      ) == 3.0):
															return number
												divisor -= 1
			raise ValueError('''That number is larger than our acceptable range.'''      )


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




