Commit 6b06a9b0 by BellCodeEditor

auto save

parent 6c920c9d
Showing with 8 additions and 6 deletions
i=3
username = "sb" # 保存在服务器数据库中的用户账号(正确的账号)
userpassword = "54088" # 保存在服务器数据库中的用户密码(正确的密码)
username = "6" # 保存在服务器数据库中的用户账号(正确的账号)
userpassword = "123456" # 保存在服务器数据库中的用户密码(正确的密码)
# 请用input()实现用户输入账号、密码的功能
while True:
if i>0:
name=input("输入:")
name=input("输入名字:")
password=input("输入密码:")
i-=1
if name ==username and password == userpassword:
print("成功")
break
elif name != username:
print("名字错")
print("名字错了")
print("还有"+str(i)+"次机会")
continue
else:
print("密码错")
print("密码错了")
print("还有"+str(i)+"次机会")
else:
print("锁定账号,你个*********")
print("锁定账号")
exit()
print("成功")
......
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