#成绩归类.py
while True:
score = eval(input(“请输入分数:”))
if score >= 60 and score < 70:
grade = “D”
elif score >= 70 and score < 80:
grade = “C”
elif score >=80 and score < 90:
grade = “B”
elif score >= 90 and score <= 100:
grade = “A”
elif score < 60:
grade = “E”
print(“分数等级为:{}”.format(grade))
python入门小程序:成绩归类
最新推荐文章于 2024-03-21 14:20:42 发布