結果

問題 No.2126 MEX Game
ユーザー gew1fw
提出日時 2025-06-12 14:44:51
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 212 bytes
コンパイル時間 351 ms
コンパイル使用メモリ 82,480 KB
実行使用メモリ 90,600 KB
最終ジャッジ日時 2025-06-12 14:46:17
合計ジャッジ時間 3,408 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 10 WA * 17
権限があれば一括ダウンロードができます

ソースコード

diff #

import bisect

n = int(input())
a = list(map(int, input().split()))
a.sort()

m = 0
while True:
    i = bisect.bisect_left(a, m)
    count_ge = n - i
    if count_ge < 2:
        print(m)
        break
    m += 1
0