D. Valentine's Cake
time limit per test
1 second
memory limit per test
64 megabytes
input
стандартный ввод
output
стандартный вывод

Rasta has bought a cake for valentine's day. He knows that his love, Rosita loves number a and he, himself loves number b. So he want to cut the cake into c pieces where c is the greatest number that a and b are both multiplies of c .

Your task is to write a program with language DIT, and storages a b 0 0 calculates number c and put it in storage number 1 (the other storages don't matter).

Your program's order mustn't exceed 2 * 107 .

Input

The numbers in the storages are a b 0 0 in order.

1 ≤ a, b ≤ 105

Output

c should be in the first storage.

Examples
Input
1 5 0 0
Output
1
Input
6 8 0 0
Output
2