摘要:
c = 1 while c < 4: a = input("请输入用户名") if a != "xu": print("登录失败") c = c + 1 elif a == "xu": print("登录成功") break print("请退出") 阅读全文
摘要:
n = 1 while n < 101: a = n % 2 if a == 1: pass else: print(n) n = n + 1 阅读全文
摘要:
n = 1 while n < 101: a = n % 2 if a == 0: pass else: print(n) n = n + 1 阅读全文
摘要:
n = 1 b = 0 while n < 101: b = n + b n = n + 1 print(b) 阅读全文
摘要:
inp = input('请输入用户名:') ina = input('请输入密码:') if inp == "许城": print('欢迎进入我的世界') if ina == "我爱你中国": print('登录成功') else: print('错误') # inp :变量 ina :变量 如果 阅读全文
摘要:
inp = input('请输入会员级别:') if inp == "高级会员": print('7000') elif inp == "铂金会员": print('5000') elif inp == "白金会员": print('2000') else: print('cuowu') print 阅读全文
摘要:
a1 = 89%2 print(a1) if a1 == 0: print("偶数") if a1 == 1: print("奇数") 阅读全文