Commit 751b0b86 by BellCodeEditor

save project

parent 4c2c1fdd
Showing with 4 additions and 5 deletions
...@@ -3,13 +3,12 @@ userpassword = "123456" ...@@ -3,13 +3,12 @@ userpassword = "123456"
while True: while True:
n = input("请输入用户名:") n = input("请输入用户名:")
p = input("请输入密码:") p = input("请输入密码:")
if n == username and p == userpassword: n == username and p == userpassword:
print("登录成功!") print("登录成功!")
break break
if n!=username: elif n!=username:
print("用户名错误!") print("用户名错误!")
continue else p!=userpassword:
if p!=userpassword:
print("密码错误!") print("密码错误!")
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