Climbing Frog
Submit solution
Points:
100
Time limit:
2.0s
Memory limit:
256M
Author:
Problem types
Allowed languages
C++, Python
A frog climbs \(u\) metres each day and slips \(d\) metres after every day except the day it reaches the top. Find when it first reaches height \(h\).
Input
One line contains integers \(h,u,d\), with \(u>d\).
The input satisfies:
- \(1 <= h,u,d <= 10^9\)
- \(u>d\)
Output
Print the number of days.
Example
Input
2 6 5
Output
1
Comments