Commit a3a85e15 by BellCodeEditor

save project

parent 3ba69be3
Showing with 19 additions and 0 deletions
b=1
score={"小明":77,"小王":86,"小张":58,"小美":100,"小丽":58}
print("输入空格退出")
while True:
a=input("请输入你的姓名:")
b=input("请输入你的最新成绩:")
if b==" " or a==" ":
break
if a in score:
if int(b)>score[a]:
score[a]=b
print("成绩更新成功")
else:
print("成绩更新失败")
else:
score[a]=int(b)
print("第一次成绩录入成功")
print(score)
\ 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