Commit 2f0e8683 by BellCodeEditor

save project

parent c8f11ac8
Showing with 5 additions and 4 deletions
student1 = {'语文': 91, '数学': 88, '英语': 85}
student2 = {'语文': 56, '数学': 36, '英语': }
student1 = {'语文': 43, '数学': 48, '英语': 35}
student2 = {'语文': 56, '数学': 36, '英语': 67 }
student3 = {'语文': 100, '数学': 100, '英语': 98}
score = {'悟空': student1, '诺依': student2, '小贝': student3}
score = {'李奕东': student1, '杨舒亦': student2, '陈熙瑷': student3}
# 查询并打印出输入的名字对应的所有科目的成绩
while True :
name = input("名字:")
name = input("请输入查询的姓名,退出输入q")
if name in score :
a = score[name]
print('*'*30)
for k,v in a.items():
print(k,v)
elif name == "q":
break
else:
print("输入错误")
......
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