Welcome to ZOJ
Information
Select Problem
Runs
Ranklist
ZOJ Problem Set - 3568
Exchange for Cola

Time Limit: 2 Seconds      Memory Limit: 65536 KB

The Cola company is holding a promotional activity that customers can exchange B bottles of Cola with A caps. Now guinao has N caps. Furthermore, guinao can ask mm to borrow him some caps for any times as long as guinao is able to return the caps borrowed after he has used these caps to exchange Cola without buying any other Cola. Please tell guinao how many number of Cola guinao can drink.

Input

This problem contains multiple test cases. Each case contains one line with three numbers N, A, B, (1 <= N <= 10^9, 1 <= B < A <= 10^9), which have already been mentioned above.

Output

Print exactly one line with the maximal number of Cola guinao can drink by exchanging caps for each test case.

Sample Input

1 2 1
9 7 2

Sample Output

1
2

Author: YING, Yuanxiang
Contest: ZOJ Monthly, December 2011
Submit    Status