|VIRTUAL JUDGE||Recent Contest||F.A.Qs||Discuss||Home||ProblemSet||Status||Ranklist||2 Contest||Login||Register||Exam|
Recall the definition of the Fibonacci numbers:
f1 := 1
f2 := 2
fn := fn-1 + fn-2 (n>=3)
The input contains several test cases. Each test case consists of two non-negative integer numbers a and b. Input is terminated by a = b = 0. Otherwise, a<=b<=10100. The numbers a and b are given with no superfluous leading zeros.
For each test case output on a single line the number of Fibonacci numbers f i with a<=fi<=b.
10 100 1234567890 9876543210 0 0
Ulm Local 2000
한국어 中文 English
All Copyright Reserved 2008-2010 SDIBT TEAM
GPL2.0 2003-2010 HUSTOJ Project TEAM
Anything about the Problems, Please Contact Admin:admin