Submit | All submissions | Best solutions | Back to list |
EIUMARKUP - Bills |
To encourage customers to buy more products, your store run discounts as the following:
- For first 100 products, each product costs 200 VND
- For the next 100 products, each product costs 199 VND
- For the next 100 products, each product cost 198 VND.
- ...
However, to make sure that the store will get some benefits, the price must be never lower than 180 for each product.
Input
The only line contains the number of product which a customer wants to buy (denoted by N, 0 <= N <= 105 )
Output
Output the amount of money the customer must pay.
Example
Input: 250 Output: 49800
Added by: | Ha Minh Ngoc |
Date: | 2017-12-04 |
Time limit: | 1s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | All except: GOSU |