-->
当前位置:首页 > 题库 > 正文内容

PROGRAMMING:Discount promotion

Luz3年前 (2021-05-10)题库274
A shopping mall launched discount promotion activities: if the customer's purchase amount is less than 100 yuan, no discount will be given; Up to or over 100 yuan, 95% discount; 10% discount if it reaches or exceeds 200 yuan; 50% discount if it reaches or exceeds 500 yuan; 20% discount if it reaches or exceeds 1000 yuan. Please write a program to calculate the actual payment amount after the discount according to the purchase amount.
####Input format
>Purchase amount
####Output format
>Payment amount
####Input sample
```in
two thousand four hundred and three point eight five
```
####Output sample
```out
one thousand nine hundred and twenty-three point zero eight
```
####Input sample 1
```in
eighty-seven point five
```
####Output sample 1
```out
eighty-seven point five zero
```
####Input sample 2
```in
two thousand four hundred and three point eight five
```
####Output sample 2
```out
one thousand nine hundred and twenty-three point zero eight
```







answer:If there is no answer, please comment

发表评论

访客

◎欢迎参与讨论,请在这里发表您的看法和观点。