結果
| 問題 |
No.736 約比
|
| コンテスト | |
| ユーザー |
nonokai10
|
| 提出日時 | 2018-09-30 13:36:09 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 270 bytes |
| コンパイル時間 | 97 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 10,880 KB |
| 最終ジャッジ日時 | 2024-10-12 09:03:18 |
| 合計ジャッジ時間 | 3,778 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 33 WA * 32 |
ソースコード
n = int(input())
a = list(map(int, input().split()))
def gcd(a, b):
while b:
a, b = b, a%b
return a
b = []
b.append(gcd(a[0], a[1]))
for i in range(2, n):
b.append(gcd(b[-1], a[i]))
gcd = b[-1]
a = [str(int(i/gcd)) for i in a]
print(":".join(a))
nonokai10