




"""simple docstring"""






import numpy as np

lowercase__			=		[
    ["""a""", """b""", """c""", """d""", """e"""],
    ["""f""", """g""", """h""", """i""", """k"""],
    ["""l""", """m""", """n""", """o""", """p"""],
    ["""q""", """r""", """s""", """t""", """u"""],
    ["""v""", """w""", """x""", """y""", """z"""],
]






class lowerCAmelCase__      :






			'''simple docstring'''



			def __init__(    self    ):
							_lowerCamelCase	:     List[Any]       =       np.array(lowercase    )
			def    A_       (    self    , lowercase    ):
							_lowerCamelCase,					_lowerCamelCase	:     Any       =       np.where(letter == self.SQUARE    )
							_lowerCamelCase	:     Optional[Any]       =       np.concatenate([indexa + 1, indexa + 1]    )
							return indexes
			def    A_       (    self    , lowercase    , lowercase    ):
							_lowerCamelCase	:     List[Any]       =       self.SQUARE[indexa - 1, indexa - 1]
							return letter
			def    A_       (    self    , lowercase    ):
							_lowerCamelCase	:     int       =       message.lower()
							_lowerCamelCase	:     Tuple       =       message.replace(' '    , ''    )
							_lowerCamelCase	:     Optional[Any]       =       message.replace('j'    , 'i'    )

							_lowerCamelCase	:     int       =       np.empty((2, len(lowercase    ))    )
							for letter_index in range(len(lowercase    )    ):
											_lowerCamelCase	:     List[Any]       =       self.letter_to_numbers(message[letter_index]    )

											_lowerCamelCase	:     Optional[int]       =       numbers[0]
											_lowerCamelCase	:     str       =       numbers[1]

							_lowerCamelCase	:     int       =       first_step.reshape(2 * len(lowercase    )    )
							_lowerCamelCase	:     int       =       ''
							for numbers_index in range(len(lowercase    )    ):
											_lowerCamelCase	:     Optional[int]       =       int(second_step[numbers_index * 2]    )
											_lowerCamelCase	:     Optional[Any]       =       int(second_step[(numbers_index * 2) + 1]    )
											_lowerCamelCase	:     Tuple       =       self.numbers_to_letter(lowercase    , lowercase    )
											_lowerCamelCase	:     Any       =       encoded_message + letter

							return encoded_message






			def    A_       (    self    , lowercase    ):
							_lowerCamelCase	:     List[str]       =       message.lower()
							message.replace(' '    , ''    )
							_lowerCamelCase	:     List[Any]       =       np.empty(2 * len(lowercase    )    )
							for letter_index in range(len(lowercase    )    ):
											_lowerCamelCase	:     Union[str, Any]       =       self.letter_to_numbers(message[letter_index]    )
											_lowerCamelCase	:     List[Any]       =       numbers[0]
											_lowerCamelCase	:     str       =       numbers[1]

							_lowerCamelCase	:     Union[str, Any]       =       first_step.reshape((2, len(lowercase    ))    )
							_lowerCamelCase	:     Union[str, Any]       =       ''
							for numbers_index in range(len(lowercase    )    ):
											_lowerCamelCase	:     Optional[int]       =       int(second_step[0, numbers_index]    )
											_lowerCamelCase	:     List[str]       =       int(second_step[1, numbers_index]    )
											_lowerCamelCase	:     str       =       self.numbers_to_letter(lowercase    , lowercase    )
											_lowerCamelCase	:     int       =       decoded_message + letter

							return decoded_message





"""simple docstring"""






import re







def 	_snake_case     (							lowercase__						):

				if len(re.findall('[ATCG]'				,       lowercase__						)						) != len(lowercase__						):
								raise ValueError('Invalid Strand'						)

				return dna.translate(dna.maketrans('ATCG'				,       'TAGC'						)						)


if __name__ == "__main__":
			import doctest

			doctest.testmod()