AtCoder Beginner Contest 148
C
Snack
AtCoder
⌀ 0
原题
← BD →
翻译中…

Problem Statement

翻译中…

Takahashi is organizing a party.

翻译中…

At the party, each guest will receive one or more snack pieces.

翻译中…

Takahashi predicts that the number of guests at this party will be $A$ or $B$.

翻译中…

Find the minimum number of pieces that can be evenly distributed to the guests in both of the cases predicted.

翻译中…

We assume that a piece cannot be divided and distributed to multiple guests.

翻译中…

Constraints

翻译中…
  • $1 \leq A, B \leq 10^5$
  • $A \neq B$
  • All values in input are integers.
翻译中…

Input

翻译中…

Input is given from Standard Input in the following format:

翻译中…

A B

翻译中…

Output

翻译中…

Print the minimum number of pieces that can be evenly distributed to the guests in both of the cases with $A$ guests and $B$ guests.

翻译中…

样例

Input #1
2 3
Output #1
6
When we have six snack pieces, each guest can take three pieces if we have two guests, and each guest can take two if we have three guests.
Input #2
123 456
Output #2
18696
Input #3
100000 99999
Output #3
9999900000
题目信息
题号
abc148_c
时间限制
2 s
内存限制
1024 MB

题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。