




"""simple docstring"""





_lowercase		 =      [chr(i) for i in range(32, 1_26)]
_lowercase		 =      list(range(len(alphabets)))
_lowercase		 =      list(range(len(alphabets)))
_lowercase		 =      list(range(len(alphabets)))
_lowercase		 =      list(reversed(range(len(alphabets))))
_lowercase		 =      []
_lowercase		 =      _lowercase		 =      _lowercase		 =      0

def 						lowerCAmelCase							(	):
						'''simple docstring'''


						global gear_one_pos
						global gear_two_pos
						global gear_three_pos
						snake_case__    :   Any							     =   gear_one[0]
						gear_one.append(lowerCamelCase						)
						del gear_one[0]
						gear_one_pos += 1
						if gear_one_pos % int(len(lowerCamelCase						)						) == 0:
												snake_case__    :   List[str]							     =   gear_two[0]
												gear_two.append(lowerCamelCase						)
												del gear_two[0]
												gear_two_pos += 1
												if gear_two_pos % int(len(lowerCamelCase						)						) == 0:
																		snake_case__    :   Optional[Any]							     =   gear_three[0]
																		gear_three.append(lowerCamelCase						)
																		del gear_three[0]
																		gear_three_pos += 1

def 						lowerCAmelCase							(	lowerCamelCase						):
						'''simple docstring'''


						snake_case__    :   Dict							     =   alphabets.index(lowerCamelCase						)
						snake_case__    :   Tuple							     =   gear_one[target]
						snake_case__    :   Any							     =   gear_two[target]
						snake_case__    :   Optional[Any]							     =   gear_three[target]
						snake_case__    :   Any							     =   reflector[target]
						snake_case__    :   int							     =   gear_three.index(lowerCamelCase						)
						snake_case__    :   List[str]							     =   gear_two.index(lowerCamelCase						)
						snake_case__    :   Optional[int]							     =   gear_one.index(lowerCamelCase						)
						code.append(alphabets[target]						)
						rotator()


if __name__ == "__main__":
							_lowercase		 =      list(input("""Type your message:\n"""))
							while True:
														try:
																					_lowercase		 =      int(input("""Please set token:(must be only digits)\n"""))
																					break
														except Exception as error:
																					print(error)
							for _ in range(token):
														rotator()
							for j in decode:
														engine(j)
							print("""\n""" + """""".join(code))
							print(
							    f"""\nYour Token is {token} please write it down.\nIf you want to decode """
							    """this message again you should input same digits as token!"""
							)








"""simple docstring"""





from __future__ import annotations

from collections.abc import Iterator
from typing import Any

class  __lowercase    :


				'''simple docstring'''


				def __init__(				self				:       List[Any] ,SCREAMING_SNAKE_CASE_				:       Any ):
										snake_case__    :   Any							     =   data
										snake_case__    :   Node | None							     =   None





				def __str__(				self				:       Union[str, Any] ):
										return F'''{self.data}'''







class  __lowercase    :


				'''simple docstring'''


				def __init__(				self				:       Optional[int] ):
										snake_case__    :   Node | None							     =   None
										snake_case__    :   Node | None							     =   None

				def __iter__(				self				:       Optional[int] ):
										snake_case__    :   Optional[int]							     =   self.front
										while node:
																yield node.data
																snake_case__    :   Optional[int]							     =   node.next

				def __len__(				self				:       Any ):
										return len(tuple(iter(self ) ) )

				def __str__(				self				:       Union[str, Any] ):
										return " <- ".join(str(SCREAMING_SNAKE_CASE_ ) for item in self )

				def  _lowerCamelCase   (				self				:       List[str] ):
										return len(self ) == 0

				def  _lowerCamelCase   (				self				:       Optional[int] ,SCREAMING_SNAKE_CASE_				:       Any ):
										snake_case__    :   int							     =   Node(SCREAMING_SNAKE_CASE_ )
										if self.is_empty():
																snake_case__    :   List[Any]							     =   node
										else:
																assert isinstance(self.rear ,SCREAMING_SNAKE_CASE_ )
																snake_case__    :   Union[str, Any]							     =   node
																snake_case__    :   int							     =   node

				def  _lowerCamelCase   (				self				:       int ):
										if self.is_empty():
																raise IndexError('''dequeue from empty queue''' )
										assert isinstance(self.front ,SCREAMING_SNAKE_CASE_ )
										snake_case__    :   List[str]							     =   self.front
										snake_case__    :   str							     =   self.front.next
										if self.front is None:
																snake_case__    :   Optional[Any]							     =   None
										return node.data





				def  _lowerCamelCase   (				self				:       Optional[int] ):
										snake_case__    :   Optional[Any]							     =   None


if __name__ == "__main__":
							from doctest import testmod

							testmod()


