Nasser's Five#12478

Nasser's Five

1 second
256 megabytes
Very easy

Nasser loves the number . He will give you two integers and .

In one operation, you can append the digit to (in decimal representation). For example, if x = 12, after one operation it becomes .

Your task is to make x > y using the minimum number of operations.

Input

Each test contains multiple test cases. The first line contains a single integer (1 \le t \le 10^4) — the number of test cases. The description of the test cases follows.

Each test case consists of a single line containing two integers and (1 \le x, y \le 10^9).

Output

For each test case, print a single integer — the minimum number of operations required to make x > y.

Examples

Example 1

Loading
Loading

Scoring

  1. Subtask ( points) : No additional constraints.