Commit 9ce7a1e8 by BellCodeEditor

save project

parent 330338e0
Showing with 3 additions and 0 deletions
...@@ -5,11 +5,14 @@ student4 = {'语文':100, '数学':100 , '英语':100 } ...@@ -5,11 +5,14 @@ student4 = {'语文':100, '数学':100 , '英语':100 }
score = {'王梓硕': student1, '谢坤辰': student2, '丸子老师': student3, '于潇然': student4} score = {'王梓硕': student1, '谢坤辰': student2, '丸子老师': student3, '于潇然': student4}
# 查询并打印出输入的名字对应的所有科目的成绩 # 查询并打印出输入的名字对应的所有科目的成绩
while True : while True :
print("现在输入你这个败家子的名字吧!如果你TM要退出,输入s")
name=input("你TM要查谁的成绩?") name=input("你TM要查谁的成绩?")
if name in score: if name in score:
ji=score[name] ji=score[name]
for k,v in ji.items(): for k,v in ji.items():
print(k,v) print(k,v)
elif name=="s":
break
else: else:
print("你TM有病吧,根本就没有这个人!!!你TM***************") print("你TM有病吧,根本就没有这个人!!!你TM***************")
......
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