結果

問題 No.356 円周上を回る3つの動点の一致
ユーザー maspy
提出日時 2020-01-02 18:06:22
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 29 ms / 5,000 ms
コード長 344 bytes
コンパイル時間 511 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-09-17 14:01:43
合計ジャッジ時間 2,869 ms
ジャッジサーバーID
(参考情報)
judge1 / judge6
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 48
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

from math import gcd

# 相対速度を持つ

a,b,c = sorted(map(int,read().split()))

x = a * c * (b - a); y = a * b * (c - a)
n = x * y // gcd(x,y); d = (b-a) * (c-a)
g = gcd(n,d); n //= g; d //= g
print('{}/{}'.format(n,d))
0