Support Forums
Text Encrypt 1.5 - Printable Version

+- Support Forums (https://www.supportforums.net)
+-- Forum: Categories (https://www.supportforums.net/forumdisplay.php?fid=87)
+--- Forum: Coding Support Forums (https://www.supportforums.net/forumdisplay.php?fid=18)
+---- Forum: Python Programming Language (https://www.supportforums.net/forumdisplay.php?fid=32)
+---- Thread: Text Encrypt 1.5 (/showthread.php?tid=1425)



Text Encrypt 1.5 - nevets04 - 10-13-2009

Credits:
This was made with the by Fallen and I. Fallen made my old code smaller, and taught me how to allow users to put in any amount of letters.

Release notes:
1.1 Allows up to 10 letters to be encrypted
1.2 No longer have to count how many letters are in the word
1.3 The Decrypter is released
1.4 Makes the program more organised
1.5 More secure and allows you to put as many letters as you want

Text encrypt 1.5
Code:
import re
while True:
    print "\n" * 80
    print "1) Encrypt"
    print "2) Decrypt"
    choice = input("What would you like to do?: ")
    if choice == 1:
        a = "znakqlxzamc"
        b = "hznalkprasdnlaskf"
    c = "qpavmdlpcianasl"
    d = "fglaspgnasfalmfnkdcoz"
    e = "ujasbofdbbspqowlamzleasn"
    f = "anslfklvlcaoalsmndnzoqlaziql"
        Word = list(raw_input("Type your word: "))
        print "".join(["".join([a,b,c,Char,d,e,f]) for Char in Word])
        raw_input("Press Enter To Continue")
    if choice == 2:
        print re.sub("(znakqlxzamc|hznalkprasdnlaskf|qpavmdlpcianasl|fglaspgnasfalmfnkdcoz|ujasbofdbbspqowlamzleasn|anslfklvlcaoalsmndnzoqlaziql)", "", raw_input("Paste in the message: "))
        raw_input("Press Enter To Continue")