题解 | #牛牛的快递#
牛牛的快递
http://www.nowcoder.com/practice/41b42e7b3c3547e3acf8e90c41d98270
import math
a = input().split()
weight = float(a[0])
price = 0
emg = a[1]
if weight <= 1:
price = 20
if emg == 'y':
price = price +5
else:
price = math.ceil(weight)+19
if emg == 'y':
price = price +5
print(price)
查看8道真题和解析