I need help with a program i am doing. it is a cryptography program. i am given a regular alphabet and a key. i need to use the user input and use the regular alphabet and use the corresponding letter in the key and that becomes the new letter. i have the basic code but need help with how to mainpulate the string to do the encryption/decryption. please help
here is my code so far:
Implements a simple substitution cypher
alpha = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
key = "XPMGTDHLYONZBWEARKJUFSCIQV"
keepGoing = True
response = menu()
if response == "1":
plain = raw_input("text to be encoded: ")
elif response == "2":
coded = raw_input("code to be decyphered: ")
elif response == "0":
print "Thanks for doing secret spy stuff with me."
keepGoing = False
print "I don't know what you want to do..."