A scheduling tool needs, for two repeating events with periods a and b, both the largest common factor of the two periods and the first moment the two events line up again. Concretely, given two positive integers a and b, compute their greatest common divisor (the largest positive integer dividing both) and their least common multiple (the smallest positive integer that is a multiple of both).
Input format
A single line with two space-separated positive integers a and b.
Output format
A single line with two space-separated integers: the gcd of a and b, then the lcm of a and b.
Constraints
- 1 ≤ a ≤ 1000000000
- 1 ≤ b ≤ 1000000000