結果

問題 No.937 Ultra Sword
ユーザー kawamochi
提出日時 2019-11-29 22:38:03
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 216 bytes
コンパイル時間 79 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 20,716 KB
最終ジャッジ日時 2024-11-21 02:30:03
合計ジャッジ時間 4,989 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 7 WA * 40
権限があれば一括ダウンロードができます

ソースコード

diff #

def gcd(a, b):
    if b==0:
        return a
    else:
        return gcd(b,a%b)

n = int(input())
a = list(map(int,input().split()))
d = a[0]
for i in a:
    d = gcd(i,d)
res = 0
for i in a:
    res+=i//d
print(res)
0