题解 | #密码游戏#
密码游戏
https://www.nowcoder.com/practice/36641ab168664384aff798ba7ce34bc1
list1 =[]
x= input()
for y in x:
list1.append(y)
# print(list1)
list2 =[]
list3 = []
for i in list1:
i=int(i)
x=(i+3)%9
list2.append(x)
# print(list2)
list3.append(list2[2])
list3.append(list2[3])
list3.append(list2[0])
list3.append(list2[1])
# print(list3)
y = ''.join('%s' %i for i in list3)
print(y)
# print(type(y))
x= input()
for y in x:
list1.append(y)
# print(list1)
list2 =[]
list3 = []
for i in list1:
i=int(i)
x=(i+3)%9
list2.append(x)
# print(list2)
list3.append(list2[2])
list3.append(list2[3])
list3.append(list2[0])
list3.append(list2[1])
# print(list3)
y = ''.join('%s' %i for i in list3)
print(y)
# print(type(y))