No.356 Coincidence of Three Moving Points on a Circle
タグ : / 解いたユーザー数 76
作問者 : 👑
tails
Problem Statement
Three moving points $P_1, P_2, P_3$ are traveling clockwise around a circle of circumference $L$, each at a constant speed.
Point $P_1$ completes one lap of the circle in $T_1$ seconds.
Point $P_2$ completes one lap of the circle in $T_2$ seconds.
Point $P_3$ completes one lap of the circle in $T_3$ seconds.
Right now, the positions of all three moving points coincide.
How many seconds from now will the positions of all three moving points next coincide?
Give your answer as an irreducible fraction.
Input
$T_1$ $T_2$ $T_3$
$1 \le T_1 \lt T_2 \lt T_3 \le 10000$
$T_1, T_2, T_3$ are all integers.
Output
Output the number of seconds until the three moving points next coincide, as an irreducible fraction.
Following the sample output, print it in the format "numerator/denominator".
Sample
Sample 1
Input
2 3 4
Output
12/1
In 12 seconds, $P_1$ makes 6 laps, $P_2$ makes 4 laps, and $P_3$ makes 3 laps, returning to their original position.
During that time, the positions of the three moving points never coincide, so the answer is 12 seconds.
Even when the answer is an integer like this, do not omit the denominator from the output.
Sample 2
Input
15 21 35
Output
105/2
In 105/2 seconds, $P_1$ makes 3.5 laps, $P_2$ makes 2.5 laps, and $P_3$ makes 1.5 laps.
Sample 3
Input
40 52 130
Output
520/3
提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。