Commit ba11fad4 by BellCodeEditor

save project

parent 4c9b0aef
Showing with 10 additions and 4 deletions
......@@ -2,9 +2,15 @@ score1 = {'语文':91,'数学':88,'英语':85}
score2 = {'语文':88,'数学':88,'英语':85}
score3 = {'语文':81,'数学':88,'英语':85}
c={'诺一':score1,'悟空':score2,'八戒':score3}
Name=input("名字:")
a=c[Name]
for i,e in a.items():
print(i,e)
while True:
Name=input("名字:")
if Name in c:
a=c[Name]
print('*'*30)
for i,e in a.items():
print(i,e)
break
else:
print("sb")
# 请对字典进行遍历,将保存的分数以键值对的形式提取打印出来
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