



from typing import List

from .keymap import KEYMAP, get_character






def 					__lowerCAmelCase		(  __lowerCamelCase	:    str	)  ->						int:






					def decorator(__lowerCamelCase	:    Optional[int]	):
										__lowerCAmelCase	   =getattr(_UpperCamelCase				,   """handle_key"""				,   []	)
										handle += [key]
										setattr(_UpperCamelCase				,   """handle_key"""				,   _UpperCamelCase	)
										return func

					return decorator






def 					__lowerCAmelCase		(  *__lowerCamelCase	:    List[str]	)  ->						Union[str, Any]:






					def decorator(__lowerCamelCase	:    Any	):
										__lowerCAmelCase	   =getattr(_UpperCamelCase				,   """handle_key"""				,   []	)
										handle += keys
										setattr(_UpperCamelCase				,   """handle_key"""				,   _UpperCamelCase	)
										return func

					return decorator






class 						__a (     SCREAMING_SNAKE_CASE				):



	def __new__(						cls							:    List[str]				,	snake_case_							:    Any				,	snake_case_							:    Union[str, Any]				,	snake_case_							:    Union[str, Any])->							Optional[int]:
						__lowerCAmelCase	   =super().__new__(cls				,	snake_case_				,	snake_case_				,	snake_case_)
						if not hasattr(snake_case_				,	"""key_handler"""):
											setattr(snake_case_				,	"""key_handler"""				,	{})
						setattr(snake_case_				,	"""handle_input"""				,	KeyHandler.handle_input)

						for value in attrs.values():
											__lowerCAmelCase	   =getattr(snake_case_				,	"""handle_key"""				,	[])
											for key in handled_keys:
																__lowerCAmelCase	   =value
						return new_cls



	@staticmethod
	def 		UpperCamelCase							(						cls							:    Tuple)->							Any:
						__lowerCAmelCase	   =get_character()
						if char != KEYMAP["undefined"]:
											__lowerCAmelCase	   =ord(snake_case_)
						__lowerCAmelCase	   =cls.key_handler.get(snake_case_)
						if handler:
											__lowerCAmelCase	   =char
											return handler(cls)
						else:
											return None







def 					__lowerCAmelCase		(  cls	:    Optional[int]	)  ->						Tuple:
					return KeyHandler(cls.__name__				,   cls.__bases__				,   cls.__dict__.copy()	)









def 					__lowerCAmelCase		(  )  ->						Tuple:
					__lowerCAmelCase	   =[]
					__lowerCAmelCase	   =1

					while len(__lowerCamelCase	) < 1E6:
										constant.append(str(__lowerCamelCase	)	)
										i += 1

					__lowerCAmelCase	   ="""""".join(__lowerCamelCase	)

					return (
					    int(constant[0]	)
					    * int(constant[9]	)
					    * int(constant[99]	)
					    * int(constant[999]	)
					    * int(constant[9999]	)
					    * int(constant[99999]	)
					    * int(constant[999999]	)
					)


if __name__ == "__main__":
				print(solution())




