Commit 130df320 by BellCodeEditor

save project

parent 98805d30
Showing with 17 additions and 3 deletions
......@@ -4,9 +4,22 @@ student3 = {'语文': 150, '数学': 150, '英语': 150, '编程': 150}
student4 = {'语文': 150, '数学': 150, '英语': 150, '编程': 150}
student5 = {'语文': 0, '数学':0, '英语': 0, '编程': 0}
score = {'l': student1, 'z': student2, 's': student5,'w':student4,'g':student3}
name = input("名字:")
for k,v in score[name].items():
while not name == "q":
name = input("再输一名字:")
if name in score:
print("q是退出")
print("*"*20,end='')
for k,v in score[name].items():
print(k,v)
print("*"*20,end='')
print("q是退出")
else:
print("q是退出")
print("*"*20,end='')
print("无")
print("*"*20,end='')
print("q是退出")
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