Amy Wong has a great bank account, but she can't count at all. Previously, she had to calculate the percentage of the total amount and she managed to do that. But after the tax scale has become progressive, it was beyond her power. Bender volunteered to write her a tax calculation program for some $1,000. It takes one integer as input - income in dollars, and also produces one integer as output - tax payable. But the lazy robot never finished debugging the program. When Amy tried to hand over this data to the bureaucrat Hermes, he refused to accept it, because he immediately saw that the calculation was wrong. Try to cope with the task, which is beyond the power of the robot!
- from the amount up to $ 10,000 inclusive, a tax of 5% is charged
- 10% tax is charged from the amount from $ 10,000 to $ 100,000 inclusive
- from the amount of $ 100,000, a tax of 15% is charged
For example, the amount of income in the current year is $200,000.
- Thus, from the amount of 100,000, a 15% tax equal to $ 15,000 will be charged
- From the amount of 10,000, a 10% tax equal to $ 9,000 will be charged
- From the amount of $ 10,000, a 5% tax equal to $ 500 will be charged
- The total tax on the entire amount of $ 200,000 will be 9,000 + 24,500