結果

問題 No.339 何人が回答したのか
ユーザー mathshab
提出日時 2017-06-29 13:06:05
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
RE  
実行時間 -
コード長 323 bytes
コンパイル時間 122 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-10-04 16:33:55
合計ジャッジ時間 3,014 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 RE * 2
other AC * 34 WA * 6 RE * 21
権限があれば一括ダウンロードができます

ソースコード

diff #

#339 how many people answer
#if difference is 0
N=int(input())
A=[int(input())for i in range(N)]
m=A[0]-A[1]
for i in range(1,N-1):
    d=A[i]-A[i+1]
    if d!=0:
        if d<0:
            d*=-1
        if m>d:
            m=d
if A[N-1]!=0:
    if m>A[N-1]:
        m=A[N-1]
S=0
for i in range(N):
    S+=A[i]//m
print(S)
0