Commit ddea08eb by BellCodeEditor

save project

parent 4f88f50e
Showing with 16 additions and 9 deletions
i=3
username = "1" # 保存在服务器数据库中的用户账号(正确的账号) username = "1" # 保存在服务器数据库中的用户账号(正确的账号)
userpassword = "1" # 保存在服务器数据库中的用户密码(正确的密码) userpassword = "1" # 保存在服务器数据库中的用户密码(正确的密码)
while True: while True:
name=input('输入账号') if i>0:
password=input('输入密码') name=input('输入账号')
if username==name and userpassword==password: i-=1
print('登录成功') if username!=name:
break print('账号不存在')
if username!=name: continue
print('用户名称错误') password=input('输入密码')
if userpassword!=password: if userpassword!=password:
print('密码错误') print('密码错误')
if username==name and userpassword==password:
print('登录成功')
break
else:
print('登录次数用完')
exit()
print("欢迎加入") 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