'''simple docstring'''


import math


def  _lowerCamelCase   (				):



     """simple docstring"""





     UpperCAmelCase_							:       Tuple       =				input('Enter message: '       )
     UpperCAmelCase_							:       Dict       =				int(input(F'''Enter key [2-{len(lowerCamelCase_       ) - 1}]: '''       )       )
     UpperCAmelCase_							:       str       =				input('Encryption/Decryption [e/d]: '       )

     if mode.lower().startswith('e'       ):
          UpperCAmelCase_							:       List[Any]       =				encrypt_message(lowerCamelCase_     ,					lowerCamelCase_       )
     elif mode.lower().startswith('d'       ):
          UpperCAmelCase_							:       Tuple       =				decrypt_message(lowerCamelCase_     ,					lowerCamelCase_       )

     # Append pipe symbol (vertical bar) to identify spaces at the end.
     print(F'''Output:\n{text + '|'}'''       )


def  _lowerCamelCase   (				lowerCamelCase_ :							int     ,					lowerCamelCase_ :							str       ):



     """simple docstring"""





     UpperCAmelCase_							:       Any       =				[''] * key
     for col in range(lowerCamelCase_       ):
          UpperCAmelCase_							:       Any       =				col
          while pointer < len(lowerCamelCase_       ):
               cipher_text[col] += message[pointer]
               pointer += key
     return "".join(lowerCamelCase_       )


def  _lowerCamelCase   (				lowerCamelCase_ :							int     ,					lowerCamelCase_ :							str       ):



     """simple docstring"""





     UpperCAmelCase_							:       str       =				math.ceil(len(lowerCamelCase_       ) / key       )
     UpperCAmelCase_							:       Optional[int]       =				key
     UpperCAmelCase_							:       Tuple       =				(num_cols * num_rows) - len(lowerCamelCase_       )
     UpperCAmelCase_							:       Union[str, Any]       =				[''] * num_cols
     UpperCAmelCase_							:       int       =				0
     UpperCAmelCase_							:       Union[str, Any]       =				0

     for symbol in message:
          plain_text[col] += symbol
          col += 1

          if (
              (col == num_cols)
              or (col == num_cols - 1)
              and (row >= num_rows - num_shaded_boxes)
          ):
               UpperCAmelCase_							:       str       =				0
               row += 1

     return "".join(lowerCamelCase_       )


if __name__ == "__main__":
 import doctest

 doctest.testmod()
 main()







'''simple docstring'''


snake_case__					:      Optional[Any]				      =  tuple[float, float, float]
snake_case__					:      Tuple				      =  tuple[float, float, float]


def  _lowerCamelCase   (				lowerCamelCase_ :							Pointad     ,					lowerCamelCase_ :							Pointad       ):



     """simple docstring"""





     UpperCAmelCase_							:       Any       =				end_pointa[0] - end_pointa[0]
     UpperCAmelCase_							:       Optional[Any]       =				end_pointa[1] - end_pointa[1]
     UpperCAmelCase_							:       Any       =				end_pointa[2] - end_pointa[2]
     return (x, y, z)


def  _lowerCamelCase   (				lowerCamelCase_ :							Vectorad     ,					lowerCamelCase_ :							Vectorad       ):



     """simple docstring"""





     UpperCAmelCase_							:       Optional[Any]       =				ab[1] * ac[2] - ab[2] * ac[1]  # *i
     UpperCAmelCase_							:       Optional[Any]       =				(ab[0] * ac[2] - ab[2] * ac[0]) * -1  # *j
     UpperCAmelCase_							:       Dict       =				ab[0] * ac[1] - ab[1] * ac[0]  # *k
     return (x, y, z)


def  _lowerCamelCase   (				lowerCamelCase_ :							Vectorad     ,					lowerCamelCase_ :							int       ):



     """simple docstring"""





     return tuple(round(lowerCamelCase_     ,					lowerCamelCase_       ) for x in vector       ) == (0, 0, 0)





def  _lowerCamelCase   (				lowerCamelCase_ :							Pointad     ,					lowerCamelCase_ :							Pointad     ,					lowerCamelCase_ :							Pointad     ,					lowerCamelCase_ :							int = 10       ):



     """simple docstring"""





     UpperCAmelCase_							:       List[str]       =				create_vector(lowerCamelCase_     ,					lowerCamelCase_       )
     UpperCAmelCase_							:       List[Any]       =				create_vector(lowerCamelCase_     ,					lowerCamelCase_       )
     return is_zero_vector(get_ad_vectors_cross(lowerCamelCase_     ,					lowerCamelCase_       )     ,					lowerCamelCase_       )






