結果

問題 No.1686 Geschenkt
ユーザー roarisroaris
提出日時 2021-09-24 21:21:28
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 96 ms / 2,000 ms
コード長 191 bytes
コンパイル時間 268 ms
コンパイル使用メモリ 87,176 KB
実行使用メモリ 71,896 KB
最終ジャッジ日時 2023-09-18 20:29:47
合計ジャッジ時間 1,945 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 96 ms
71,652 KB
testcase_01 AC 96 ms
71,428 KB
testcase_02 AC 93 ms
71,632 KB
testcase_03 AC 95 ms
71,620 KB
testcase_04 AC 94 ms
71,644 KB
testcase_05 AC 93 ms
71,536 KB
testcase_06 AC 93 ms
71,756 KB
testcase_07 AC 96 ms
71,724 KB
testcase_08 AC 95 ms
71,748 KB
testcase_09 AC 95 ms
71,896 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline
from collections import *

N = int(input())
A = list(map(int, input().split()))
ans = 0

for Ai in A:
    if Ai-1 not in A:
        ans += Ai

print(ans)
0