Pay for the purchase without change#8534

Pay for the purchase without change

1 second
64 megabytes
Medium

In a certain country, coins are available in two denominations: and units. How many different ways can you pay for a purchase costing units using these coins, so that no change is required? Two ways are considered different if they differ in the number of coins of at least one denomination.

Input

The input consists of a single line containing three positive integers: , , and , where N, M1, M2 < 10^6 and M1 \neq M2.

Output

Output a single number — the answer to the problem.

Examples

Example 1

Loading
Loading