Skip to main content
Tuesday (24.11.2026) at 20:00: ALGOR Contest: Round #4 (Special Challenge) starts!

~/algor $ cat problems/if-elektr-tolovi

Electricity bill

Medium 1000 ms 64 MB 41%
Share

In a month, $k$ kilowatt-hours of electricity were used. The bill is computed in tiers: each of the first $200$ kilowatt-hours costs $600$ soums, each kilowatt-hour from the $201$st to the $1000$th costs $900$ soums, and each kilowatt-hour above $1000$ costs $1200$ soums. Find the monthly bill in soums.

An electricity bill by a three-tier tariff

Input

One integer $k$.

Output

One integer — the amount to pay.

Note

$0 \le k \le 10^{6}$

Examples

Input #1
150
Output #1
90000
Input #2
350
Output #2
255000

Sign in to submit a solution

Signing up is free and takes a minute.