Commit f6c4d39e by BellCodeEditor

auto save

parent 1c197d62
Showing with 45 additions and 20 deletions
import random
# 私钥
key = "abcdefgh使用编程实现位移替换加密,制作密码机关真是太好玩了哈哈!"
# 要加密语句
message = "诺依,周末一起去看动漫展吧!"
key_message=""
# 请使用私钥key,对message进行加密
for i in range(len(message)):
a=message[i]
b=random.choice(key)
c=random.choice(key)
d=a+b+c
key_message=key_message+d
print(key_message)
message1=list(key_message)
message1.insert(random.randint(0,len(message1)),"¥%……&*$%_*^&%(%^")
message2="".join(message1)
print(message2)
\ No newline at end of file
# # # # # import random
# # # # # # 私钥
# # # # # key = "abcdefgh使用编程实现位移替换加密,制作密码机关真是太好玩了哈哈!"
# # # # # # 要加密语句
# # # # # message = "诺依,周末一起去看动漫展吧!"
# # # # # text_mes = ''
# # # # # for i in message:
# # # # # str1 = i
# # # # # str2 = random.choice(key)
# # # # # str3 = random.choice(key)
# # # # # text = str1+str2+str3
# # # # # text_mes = text_mes+text
# # # # # print(tex
# # # # # 输入函数:input ("提示语句") 输入内容默认字符串类型
# # # # one,two = input("输入").split()
# # # # print(one)
# # # # print(two)
# # # # split()方法结合input使用可以实现一次完成多个数据赋值
# # # # 第一种方法
# # # # a,b,c = input("输入").split()
# # # # a = int(a)
# # # # b = int(b)
# # # # c = int(c)
# # # # print((a+b)*c)
# # # #第二种方法
# # # a,b,c = map(int,input("输入").split())
# # # print((a+b)*c)
# # a,b=map(int,input("数字").split())
# # print(a+b)
# name = input("输入姓名")
# print("你好"+name)
a = int(input("数字"))
print(a*3)
\ 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