Commit 1da830f5 by BellCodeEditor

save project

parent c7d3556e
Showing with 15 additions and 9 deletions
i=3
username = "cy"
userpassword = "123456"
while True:
name = input("记得你的名字吗?:")
password = input("记得你的密码吗?:")
if name == username and password == userpassword:
print("对啦!")
break
elif name!=username:
print("你的名字错了")
elif password!=userpassword:
print("你的密码错了")
if i>0:
name = input("记得你的名字吗?:")
password = input("记得你的密码吗?:")
i-=1
if name == username and password == userpassword:
print("对啦!")
break
elif name!=username:
print("你的名字错了")
elif password!=userpassword:
print("你的密码错了")
else:
print("你应该去找别人问问")
print("欢迎回来")
\ 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