import
java.util.Scanner;
public class
demo03 {
public
static
void
main(String[] args)
{
Scanner in =
new
Scanner(System.in);
int
a = in.nextInt();
int
b = in.nextInt();
int
i =
0
;
while
(
true
)
{
i++;
if
(i%a==
0
&& i%b==
0
&& i>=a && i>=b)
{
System.out.println(
"最小公倍数为:"
+i);
i=
0
;
break
;
}
}
int
yue =
0
;
while
(
true)
{
i++;
if
(a%i==
0
&& b%i==
0
){
yue = i;
}
if
(i>a || i>b)
break
;
}
System.out.println(
"最大公约数为:"
+yue);
}
}