Commit 1ffcf67a by BellCodeEditor

save project

parent 0dfb032f
Showing with 51 additions and 15 deletions
username = "python" # 保存在服务器数据库中的用户账号(正确的账号)
userpassword = "123456" # 保存在服务器数据库中的用户密码(正确的密码)
i=input("用户账号")
p=input("用户密码")
t = 3
username = "python"
userpassword = "123456"
while True:
if i == username and p == userpassword:
print("登陆成功")
break
if i !=username:
print("用户不存在")
break
if p !=userpassword:
print("密码输入有误")
break
# 如果用户输入的账号、密码正确,提示登陆成功
if t>0:
i=input("用户账号")
p=input("用户密码")
t-=1
if i == username and p == userpassword:
print("登陆成功")
break
if i !=username:
print("用户不存在")
continue
if p !=userpassword:
print("密码错误")
continue
else:
print("账号被冻姐")
exit()
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