Elevator
To move a new refrigerator to the N-th floor of a M-story building, Vitya hired a team of movers. The cost for the movers' work is structured as follows: lifting the refrigerator up one floor costs 200 rubles, while lowering it down one floor costs 100 rubles. There is no charge for using the elevator to go up or down. Although Vitya's building has an elevator, he might still incur costs because the elevator only stops on every K-th floor, starting from the first (i.e., on floors numbered 1, K+1, 2K+1, 3K+1, ...). Your task is to calculate the minimum amount of money needed for the movers to deliver the refrigerator from the first floor to the N-th floor.
Input
The input file contains three numbers: M (2 ≤ M ≤ 100), N (2 ≤ N ≤ M), and K (2 ≤ K ≤ M-1), separated by spaces.
Output
Output a single number - the minimum cost of lifting the refrigerator.