input: def generate_rsa_key_pair():
      """
      Generate an RSA public/private key pair and save them to files.
  
      >>> from os.path import exists
      >>> generate_rsa_key_pair()
      >>> exists('public.pem')
      True
      >>> exists('private.pem')
      True
      """
      from Crypto.PublicKey import RSA
      key = RSA.generate(2048)
      pub_key = key.publickey().export_key().decode()
      with open('public.pem', 'w') as file:
          file.write(pub_key)
  
      priv_key = key.export_key().decode()
      with open('private.pem', 'w') as file:
          file.write(priv_key)
output:     from Crypto.PublicKey import RSA
      key = RSA.generate(2048)
      pub_key = key.publickey().export_key().decode()
      with open('public.pem', 'w') as file:
          file.write(pub_key)
  
      priv_key = key.export_key().decode()
      with open('private.pem', 'w') as file:
          file.write(priv_key)