#Python TQC考題208_十進位換算
n = int(input())
#輸入浮點數會錯誤,改為
# n=int(eval(input()))
#把input用eval轉為數值,
#再將數值用int取整數(無條件捨去法)
if n <=9:
print(n)
elif n == 10:
print(“A”)
elif n == 11:
print(“B”)
elif n == 12:
print(“C”)
elif n == 13:
print(“D”)
elif n == 14:
print(“E”)
elif n == 15:
print(“F”)
Spyder執行結果:





![Python爬蟲:BeautifulSoup的 .find_all() 與 .find() 與 .select(‘標籤名[屬性名1=”屬性值1″][屬性名2=”屬性值2″]’) ; from bs4 import BeautifulSoup ; Live Server(可以預覽HTML的VS Code套件) Python爬蟲:BeautifulSoup的 .find_all() 與 .find() 與 .select(‘標籤名[屬性名1=”屬性值1″][屬性名2=”屬性值2″]’) ; from bs4 import BeautifulSoup ; Live Server(可以預覽HTML的VS Code套件)](https://i1.wp.com/savingking.com.tw/wp-content/uploads/2025/03/20250330190318_0_925655.jpg?quality=90&zoom=2&ssl=1&resize=350%2C233)








近期留言