Commit 4111a5bd by BellCodeEditor

save project

parent 19564125
Showing with 10 additions and 23 deletions
username = "python" import turtle
userpassword = "123456" pen=turtle.Pen()
i=3 distance=1
while True: for i in range(300):
if i>0: pen.forward(distance)
a = input("请输入用户名:") pen.left(91)
b = input("请输入密码:") distance+=1
i-=1 pen.hideturtle()
if a == username and b == userpassword: turtle.done()
break \ No newline at end of file
print("登录成功!")
if a!=username:
print("用户名错误!请重新输入")
print("还有"+str(i)+"次")
continue
if b!=userpassword:
print("密码错误!请重新输入")
print("还有+str(i)+次")
else:
print("登录锁定")
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