Commit 63e3169f by BellCodeEditor

auto save

parent 6fb3d5b3
Showing with 9 additions and 5 deletions
student1 = {'语文': 9728, '数学': 8684, '英语': 9744} student1 = {'语文': 9728, '数学': 8684, '英语': 9744}
student2 = {'语文': 8266, '数学': 9547, '英语': 9845} student2 = {'语文': 8266, '数学': 9547, '英语': 9845}
student3 = {'语文': 9458, '数学': 9875, '英语': 8884} student3 = {'语文': 9458, '数学': 9875, '英语': 8884}
score = {'悟空': student1, '诺依': student2, '小贝': student3} score = {'悟空': student1, '诺依': student2, '小贝': student3}
name=input('名子:') name=input('名子:')
info=score[name] if name in score:
for k,v in info.items(): score=score[name]
print(k,v) for k,v in score.items():
\ No newline at end of file print(k,v)
print('*'*30)
else:
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