結果

問題 No.2335 Jump
ユーザー aaaaaaaaaa2230aaaaaaaaaa2230
提出日時 2023-06-02 21:46:46
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 99 ms / 2,000 ms
コード長 118 bytes
コンパイル時間 414 ms
コンパイル使用メモリ 87,120 KB
実行使用メモリ 92,712 KB
最終ジャッジ日時 2023-08-28 03:07:34
合計ジャッジ時間 3,303 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 72 ms
70,944 KB
testcase_01 AC 72 ms
71,220 KB
testcase_02 AC 71 ms
71,376 KB
testcase_03 AC 70 ms
71,060 KB
testcase_04 AC 72 ms
71,088 KB
testcase_05 AC 72 ms
71,348 KB
testcase_06 AC 72 ms
71,328 KB
testcase_07 AC 72 ms
71,292 KB
testcase_08 AC 73 ms
71,424 KB
testcase_09 AC 72 ms
71,236 KB
testcase_10 AC 71 ms
71,060 KB
testcase_11 AC 72 ms
71,224 KB
testcase_12 AC 97 ms
92,640 KB
testcase_13 AC 97 ms
92,528 KB
testcase_14 AC 98 ms
92,624 KB
testcase_15 AC 97 ms
92,604 KB
testcase_16 AC 98 ms
92,664 KB
testcase_17 AC 95 ms
91,540 KB
testcase_18 AC 98 ms
92,712 KB
testcase_19 AC 99 ms
92,532 KB
testcase_20 AC 94 ms
91,544 KB
testcase_21 AC 95 ms
91,892 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
A = [0]+list(map(int,input().split()))
ans = 0
for a,na in zip(A,A[1:]):
    ans += na-a-1
print(ans)
0