Number of multiplier

View as PDF

Submit solution

Points: 1.00
Time limit: 1.0s
Memory limit: 512M
Input: stdin
Output: stdout

Author:
Problem types

Attempt

Please login to see your submissions result.


Last updated: on Dec. 17, 2024, 8:31 a.m.

Problem

Given two numbers ~N~ and ~X~, how many multiples of ~N~ do not exceed ~X~?

Input

First line contain single integers ~T~ is the number of test case.

Next ~T~ lines, each line contains two integers ~N, X~.

Output

Each test case, please output single integer ~B~ is the number multiples of ~N~ that do not exceed ~X~.

Constraints

~1 \leq T \leq 10^5~.
~1 \leq N \leq X \leq 10^{18}~.

Sample

Sample Input Sample Output
2 2 7 5 10
4 3

Explanation

In the Sample test #1, we have ~4~ multiples of ~N~ that do not exceed ~X~ is ~0, 2, 4, 6~.


Comments

Please read the guidelines before commenting.


There are no comments at the moment.