Commit f64ff23c by BellCodeEditor

save project

parent 1bad4756
Showing with 4 additions and 15 deletions
username = "python" with open("C:\Users\Administrator\Desktop\book.txt",encdoding='utf-8') as file:
userpassword = "123456" file.write('小强:10本\n')
while True: file.write('李明:15本\n')
name = input("请输入用户名:") \ No newline at end of file
password = input("请输入密码:")
if username != name:
print("账号错误")
continue
if password != userpassword:
print("密码错误")
if name == username and password == userpassword:
print("登录成功!")
break
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