






"""simple docstring"""



import math
def 		_SCREAMING_SNAKE_CASE					(       __snake_case     :    int       ):





  '''simple docstring'''





  if n <= 0:
    raise ValueError('Only positive integers have prime factors'       )
  lowercase				       =			[]
  while n % 2 == 0:
    pf.append(2       )
    lowercase				       =			int(n / 2       )
  for i in range(3						,   int(math.sqrt(__snake_case       )       ) + 1						,   2       ):
    while n % i == 0:
      pf.append(__snake_case       )
      lowercase				       =			int(n / i       )
  if n > 2:
    pf.append(__snake_case       )
  return pf
def 		_SCREAMING_SNAKE_CASE					(       __snake_case     :    int       ):





  '''simple docstring'''





  if n <= 0:
    raise ValueError('Only positive numbers are accepted'       )
  lowercase				       =			1
  lowercase				       =			1
  while n % 2 == 0:
    temp += 1
    lowercase				       =			int(n / 2       )
  div *= temp
  for i in range(3						,   int(math.sqrt(__snake_case       )       ) + 1						,   2       ):
    lowercase				       =			1
    while n % i == 0:
      temp += 1
      lowercase				       =			int(n / i       )
    div *= temp
  if n > 1:
    div *= 2
  return div
def 		_SCREAMING_SNAKE_CASE					(       __snake_case     :    int       ):





  '''simple docstring'''





  if n <= 0:
    raise ValueError('Only positive numbers are accepted'       )
  lowercase				       =			1
  lowercase				       =			1
  while n % 2 == 0:
    temp += 1
    lowercase				       =			int(n / 2       )
  if temp > 1:
    s *= (2**temp - 1) / (2 - 1)
  for i in range(3						,   int(math.sqrt(__snake_case       )       ) + 1						,   2       ):
    lowercase				       =			1
    while n % i == 0:
      temp += 1
      lowercase				       =			int(n / i       )
    if temp > 1:
      s *= (i**temp - 1) / (i - 1)
  return int(__snake_case       )
def 		_SCREAMING_SNAKE_CASE					(       __snake_case     :    int       ):





  '''simple docstring'''





  lowercase				       =			n
  for x in set(prime_factors(__snake_case       )       ):
    s *= (x - 1) / x
  return int(__snake_case       )


if __name__ == "__main__":
    import doctest

    doctest.testmod()










from typing import Literal

lowerCamelCase					    =	'''ABCDEFGHIJKLMNOPQRSTUVWXYZ'''
def 							UpperCAmelCase   ( _lowercase,   _lowercase,   _lowercase   ):


    '''simple docstring'''



    _lowercase     			=						LETTERS if mode == 'decrypt' else key
    _lowercase     			=						key if mode == 'decrypt' else LETTERS
    _lowercase     			=						''
    # loop through each symbol in the message
    for symbol in message:
        if symbol.upper() in chars_a:
            # encrypt/decrypt the symbol
            _lowercase     			=						chars_a.find(symbol.upper()   )
            if symbol.isupper():
                translated += chars_b[sym_index].upper()
            else:
                translated += chars_b[sym_index].lower()
        else:
            # symbol is not in LETTERS, just add it
            translated += symbol
    return translated
def 							UpperCAmelCase   ( _lowercase,   _lowercase   ):


    '''simple docstring'''



    return translate_message(_lowercase,   _lowercase,   'encrypt'   )
def 							UpperCAmelCase   ( _lowercase,   _lowercase   ):


    '''simple docstring'''



    return translate_message(_lowercase,   _lowercase,   'decrypt'   )
def 							UpperCAmelCase   ( ):


    '''simple docstring'''



    _lowercase     			=						'Hello World'
    _lowercase     			=						'QWERTYUIOPASDFGHJKLZXCVBNM'
    _lowercase     			=						'decrypt'  # set to 'encrypt' or 'decrypt'

    if mode == "encrypt":
        _lowercase     			=						encrypt_message(_lowercase,   _lowercase   )
    elif mode == "decrypt":
        _lowercase     			=						decrypt_message(_lowercase,   _lowercase   )
    print(f'''Using the key {key}, the {mode}ed message is: {translated}'''   )


if __name__ == "__main__":
   import doctest

   doctest.testmod()
   main()
