program main
  implicit none
  integer(8) i, a, b, a1, b1
  read(*, *)a, b
  a1 = a
  b1 = b
  !read(*, *) (L(i), i = 1,N)
  !ユークリッドの互除法でaとbの最大公約数を求めます。
  do
    if (a == b) then
      exit
    elseif (a > b) then
      a = a-b
    else
      b = b-a
    end if
  end do
      

  write(*, *) (a1*b1)/a
end program main
