NSUJ03C - Digibomb!

Nayeem rushed to you with a sad, helpless look in his eyes. One part of his program needs to multiply two integers and find the number of digit it has. Now the problem is these numbers can be very big - as big as 18 digits. Everytime Nayeem tries to multiply them they overflow - since long long can only handle numbers less then 2^63-1, which is roughly 19 digits.

Nayeem believes you are super smart and you can help him this time. Can you write him that part of the program?

Input

First line will contain number of test cases t.
Each case will have two integers a and b. Both are less than 10^19.

Output

For each case output how many digits will be there in the product of a,b.

Example

Input:
4
100 100
10000 10000
100000 100000
1000000001804289383 1000000000846930886 Output: 5
9
11
37

Added by:Iqram Mahmud
Date:2011-07-03
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ASM64
Resource:Own

© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.