結果

問題 No.135 とりあえず1次元の問題
ユーザー naoe123naoe123
提出日時 2020-01-16 09:55:40
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
RE  
実行時間 -
コード長 251 bytes
コンパイル時間 73 ms
コンパイル使用メモリ 10,732 KB
実行使用メモリ 19,784 KB
最終ジャッジ日時 2023-09-05 14:31:14
合計ジャッジ時間 1,890 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 88 ms
19,580 KB
testcase_01 AC 17 ms
7,976 KB
testcase_02 AC 16 ms
7,828 KB
testcase_03 RE -
testcase_04 WA -
testcase_05 AC 16 ms
7,940 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 AC 16 ms
7,744 KB
testcase_20 WA -
testcase_21 AC 78 ms
18,892 KB
testcase_22 AC 85 ms
19,784 KB
evil01.txt AC 86 ms
19,776 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N=int(input())
X=list(map(int,input().split()))

distance=[]

if N!=1:
    for i in range(N-1):
        distance.append(abs(X[i]-X[i+1]))
else:
    pass

distance=[i for i in distance if i!=0]

if len(X)!=0:
    print(min(distance))
else:
    print(0)
0