练21.2 邮寄包裹
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
说明
邮局对邮寄包裹有如下规定:若包裹的重量超过 千克,不予邮寄,对可以邮寄的包裹每件收手续费 元,再加上根据下表按重量 计算的结果。
重量(千克) | 收费标准(元/公斤) |
$x≤10$ | $0.80$ |
$10< x≤20$ | $0.75$ |
$20< x≤30$ | $0.70$ |
请你编写一个程序,输入包裹重量,输出所需费用或"
Fail
"表示无法邮寄。
输入格式
输入一个整数 ,表示包裹的重量(单位:千克)。()
输出格式
输出对应的费用(答案保留 位小数)或"Fail
"表示无法邮寄。
样例
7
5.80
初中活動課_Python第一次比賽
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 8
- Start at
- 2025-6-19 15:00
- End at
- 2025-6-19 16:12
- Duration
- 1.2 hour(s)
- Host
- Partic.
- 26