title: Use variables as parameter in imported function
body: <p>I'm pretty new to python, so this might have a really obvious and simple solution, but here it is:
  I created a custom module, imported it into another script [script2], and want to use local variables defined in script2 as the parameters for a function from the imported module</p>
  
  <p>Module:</p>
  
  <pre><code>def encrypt(inputstr, securitykey = 1, encryptionkey = 1, decryptionkey = 1): #default value of keys is 1
  
  inputstr = str(inputstr)
  
  [converts inputed string into number ids based on encryption key and security key; this is like a 80 line long process, so I won't show it here]
  
  inputstr = int(inputstr)
  inputstr = inputstr * decryptionkey * securitykey
  inputstr = str(int(inputstr)) #&lt;this is stupid, I know, but for some reason this was the only way it worked
  
  return inputstr
  </code></pre>
  
  <p>script2:</p>
  
  <pre><code>from ModuleDirectory import encryption
  
  msg = input("Enter your message: \n \n")
  seckey = input("Enter security key: \n \n")
  enckey = input("Enter enrcyption key: \n \n")
  deckey = input("Enter decryption key: \n \n")
  
  encrypted = encryption.encrypt(msg,seckey,enckey,deckey)
  print(encrypted)
  </code></pre>
  
  <p>When I do this, I get a NameError. How do I tell Python that I want to use the variables defined in script2 as the parameters for the function I imported from the module? As I said, I'm pretty new to Python, so I could just be being an idiot.</p>