409995: GYM103895 E Feed Worm

Memory Limit:256 MB Time Limit:1 S
Judge Style:Text Compare Creator:
Submit:0 Solved:0

Description

E. Feed Wormtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output

After spending years as a nematologist, you've finally acquired yourself a pet worm. Unfortunately, since it's your first pet worm, you're unsure of your ability to maintain its welfare.

Your worm begins with $$$F$$$ fullness. Every day, you feed it, increasing its fullness by $$$A$$$. Every night, it consumes energy, losing $$$B$$$ fullness.

Your worm will finally be happy as soon as it reaches or exceeds $$$1000$$$ fullness.

Given the worm's initial fullness and your feeding regimen, determine how many days it will take before the worm gets full (or that it will never become full).

Input

A single line with values $$$0 \leq F \leq 999$$$, $$$1 \leq A, B \leq 100$$$.

Output

The day on which the worm becomes full, or $$$-1$$$ if this never occurs.

ExamplesInput
900 50 25
Output
3
Input
500 10 10
Output
-1

加入题单

算法标签: