L. Ayanoto 变形记
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

可怜的 Ayanoto 被巫师变成了一只小青蛙。

巫师把他放到圆环上的某一点,并告诉他,如果你从这里出发,并能再次到这里,就能变回人类。

圆环上有 $$$n$$$ 个点,简便起见编号为 $$$0$$$ 到 $$$n-1$$$。

由于是青蛙的体型,他每一步只能跳确切的 $$$x$$$ 个长度。

比如说,如果他现在在 $$$0$$$ 号点,那么下一步,他可以向前跳到第 $$$x$$$ 个点。

请你判断,经过不断的跳跃后,Ayanoto是否有可能变为人类。

Input

$$$t$$$ 组输入 $$$(1 \le t \le 10^3)$$$。

每组输入包含两个数字 $$$n(2 \le n \le 10^6), x(0\le x \le 10^6)$$$。

Output

$$$t$$$ 行输出,如果 Ayanoto 可以变为人类输出 "yes"(没有引号),否则输出 "no"(没有引号)。

Examples
Input
2
3 1
4 2
Output
yes
yes
Input
2
3 2
13 0
Output
yes
no