Commit f41db2c7 by BellCodeEditor

save project

parent 481f9b53
Showing with 7 additions and 7 deletions
...@@ -5,14 +5,14 @@ name = input("请输入账号") ...@@ -5,14 +5,14 @@ name = input("请输入账号")
pa = input("请输入密码") pa = input("请输入密码")
# 请用input()实现用户 # 请用input()实现用户
while True: while True:
if name==username and pa==userpassword: if name == username and pa == userpassword:
print("登录成功")# 如果用户输入的账号、密码正确,提示登陆成功 print("登入成功")
break break
if name !=username : if name != userpassword:
print("账号错了,请重新输入。") print("账号错")
if name !=userpassword: continue
print("密码错了,请重新输入。") if pa != userpassword:
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