Skip to content
  • P
    Projects
  • G
    Groups
  • S
    Snippets
  • Help

Administrator / lesson4_5

  • This project
    • Loading...
  • Sign in
Go to a project
  • Project
  • Repository
  • Issues 0
  • Merge Requests 0
  • Pipelines
  • Wiki
  • Snippets
  • Members
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Branches
  • Tags
  • Contributors
  • Graph
  • Compare
  • Charts
Switch branch/tag
  • lesson4_5
  • wd.py
Find file
BlameHistoryPermalink
  • BellCodeEditor's avatar
    save project · 0c70a645
    BellCodeEditor committed 2 years ago
    0c70a645
wd.py 1.72 KB
Edit
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
#在控制台输入input要换算的人民币,打印出卢布 print(人民币和卢布的换算) 人民币  :卢布  =1:10.4
#rate_exchange = int(input('请输入人民币:'))
#count= rate_exchange * 10.4
#print('换算成卢布为:'+str(count)
      
#在控制台输入商品的名称 输出 价格  (可口可乐  4   百事  4   薯片  6    )   if ---elif--  else
# goods=input('请输入商品名称:')
# if  goods == '可口可乐' or goods=='百事':
#     print('4元')
# elif  goods=='薯片':
#     print('6元')
# else:
#     print('没有货物')
#       
#输入一个年份 计算是否是闰年    如果年份能整除100  年份除400
# years=int(input('请输入年份:'))
# if years % 100 ==0  and years % 400==0:
#     print('是闰年')
# elif years % 100 != 0  and years % 4 ==0 :
#     print('是闰年')
# else:
#     print('不是')
a = "python"
b = "123456"
e = 0
i = 3
while e < 3:
    c = input("请输入用户名: ")
    d = input("请输入密码: ")
    if a == c and b == d:
        print("登录成功")
        print("欢迎来到贝尔编辑器")
        break
    elif a != c and b == d:
        print("用户名错误")
        e += 1
        i -= 1
        print("还可登录{i}次")
    elif a == c and b != d:
        print("密码错误")
        e += 1
        i -= 1
        print("还可登录{i}次")
    else:
        print("该账号不存在")
        e += 1
        i -= 1
        print("还可登录{i}次")
print("账号封锁中")
print("账号已封锁")
# print("请三分钟后尝试")
# print("自爆准备")
# print("程序删除中")
# print("删除完毕")
# print(3)
# print(2)
# print(1)
# print(0)
# print("Boom!!!")