Commit 039c8854 by BellCodeEditor

save project

parent 4555f9bf
Showing with 7 additions and 3 deletions
......@@ -4,6 +4,7 @@ i=3
# 请用input()实现用户输入账号、密码的功能
while True:
if i>0:
i-=1
name=input("用户名")
password=input("密码")
if name==username and password==userpassword:
......@@ -11,10 +12,12 @@ while True:
break
if name!=username:
print("用户名不存在")
else:
if password!=userpassword:
print("你还有"+stri+"次")
elif password!=userpassword:
print("密码错误")
exit
print("你还有"+stri+"次")
else:
exit()
print("登录成功,欢迎来到贝尔世界")
# 如果用户输入的账号、密码正确,提示登陆成功
\ No newline at end of file
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