結果
問題 | No.736 約比 |
ユーザー |
|
提出日時 | 2018-12-15 15:05:26 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 33 ms / 2,000 ms |
コード長 | 433 bytes |
コンパイル時間 | 331 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 11,392 KB |
最終ジャッジ日時 | 2024-09-25 06:16:08 |
合計ジャッジ時間 | 4,197 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 65 |
ソースコード
from functools import reduceimport mathimport decimaldef e(a, b):if a < b:return e(b,a)if (a % b) == 0:return belse:return e(b, a%b)n = int(input())ar = list(map(decimal.Decimal, input().split()))isFirst=Truefor a in ar:if isFirst:g = aisFirst = Falseelse:g = e(g,a)s=""for a in ar:s += ":{}".format(decimal.Decimal(a/g))print (s[1:])