Seryozha loves math problems very much. Recently, at a mathematical circle, he was told what GCD and NOC are.
gcd of two natural numbers a
and b
— is their greatest common divisor, that is, the maximum number x
such that a
is divisible by x
and b
is divisible by x
. For example, \(gcd(24, 18) = 6\). And the LCM of integers a
and b
— is their least common multiple, that is, the minimum number x
such that x
is divisible by a
and x
is divisible by b
. For example, \(LCC(24, 18) = 72\).
Seryozha immediately noticed that there can be several pairs of numbers with the same GCD and LCM. Now he was interested in the question: given the numbers a
and b
, how close can two numbers be that have the same gcd and lcm.
Help him given two numbers a
and b
to find numbers x
and y
such that \(gcd(a, b) = gcd(x, y)\), \(gcd(a, b) = gcd (x, y)\) and their difference \(y - x\) is minimal.
Input
The first line of the input file contains two natural numbers a
and b
(\(1 <= a, b <= 10 ^9\)).
Output data
Print two natural numbers
x
and
y
(
\(1 <= x <= y\)) , such that
\(gcd(a, b) = gcd(x, y)\),
\( LCM(a, b) = LCM(x, y)\) and their
\(y - x\) difference is minimal.
Examples
Запрещенные операторы:gcd