score = 20
if score >= 60:
print("你已经及格")
if score >= 80:
print("你很优秀")
else:
print("你只是一般般")
else:
print("不及格")
if score < 30:
print("学渣")
else:
print("还能抢救一下")
print("程序结束")

Python的if....else嵌套

 

相关文章:

  • 2022-01-03
  • 2022-12-23
  • 2021-11-02
  • 2021-09-10
猜你喜欢
  • 2021-11-30
  • 2022-12-23
  • 2021-06-08
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-31
相关资源
相似解决方案