Commit 3f229c5e by BellCodeEditor

save project

parent 2a840a91
Showing with 5 additions and 3 deletions
import random import random
luanma='9012MXUD8947NX8E1mweini8912738N129' luanma='!@#(47N--`X8E1m,weini=8912738N1*+@29'
# 私钥 # 私钥
ky = "abcdefgh使用编程实现位移替换加密,制作密码机关真是太好玩#$%*&^$@#!了哈哈!" ky = "abcdefgh使用编程实现位移替换加密,制作密码机关真是太好玩#$%*&^$@#!了哈哈!"
# 要加密语句 # 要加密语句
m = "诺依,周末一起去看动漫展吧!" m = "诺依,周末一起去看动漫展吧!"
w=[1,2,3] w=[1,2,3]
e=[1,2,3,4,5,6,7,8]
# 请使用私钥key,对message进行加密 # 请使用私钥key,对message进行加密
s_='' s_=''
for i in m: for i in m:
...@@ -13,7 +14,7 @@ for i in m: ...@@ -13,7 +14,7 @@ for i in m:
s3=random.choice(ky) s3=random.choice(ky)
t=s1+s2+s3 t=s1+s2+s3
s_=s_+t s_=s_+t
s_=list(m) s_=list(s_)
s_.insert(5,luanma) s_.insert(random.choice(e),luanma)
r_=''.join(s_) r_=''.join(s_)
print(r_) print(r_)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment