1. 程式人生 > >python3.7-初學篇-12

python3.7-初學篇-12

score = int ( input ( '請輸入一個分數:' ) )
if 100 >= score >= 90:
print('A')
if 90 > score >= 80:
print('B')
if 80 > score >= 80:
print('C')
if 60 > score >= 0:
print('D')
if score < 0 or score > 100:
print('輸入錯誤!')