Problem A. Astroturfing

Author:A. Klenin   Time limit:1 sec
Input file:input.txt   Memory limit:256 Mb
Output file:output.txt  

Statement

Well-known Internet company "Dalstolb" created an on-line marketplace, where individuals and companies can sell some products. After purchasing and testing the product, buyer can rate the seller with an integer number from 1 to 10. For each seller, website displays number of ratings N and their average A so that prospective buyers can choose better sellers.

If a company is not satisfied with its rating, it might either improve the quality of their goods and services, or create some fake accounts and give high ratings from those accounts to itself. That practice is called astroturfing.

"Dalstolb" is aware of astroturfing and implemented following limits to make it harder: each buyer may give only one rating to a given seller; all ratings strictly greater than twice the current average are flagged for manual inspection.

Your program must calculate the minimum number of fake accounts required to raise the rating to at least B, while not triggering manual inspection.

Note that all calculations by "Dalstolb" server are assumed to be absolutely exact, with no loss of precision at all.

In the first example, ratings and averages are as follows:

Fake account no.Fake ratingAverage rating
142.40000
242.66667
353.00000
463.37500
563.66667
674.00000

Input file format

Input file contains integers N A B.

Output file format

Output file must contain a single integer — minimum number of fake accounts.

Constraints

1 ≤ N ≤ 108, 1 ≤ A < B ≤ 9

Sample tests

No. Input file (input.txt) Output file (output.txt)
1
4 2 4
6
2
182736 1 9
8040384
3
2 8 9
2

0.078s 0.010s 13