結果

問題 No.2777 Wild Flush
ユーザー 寝癖寝癖
提出日時 2024-06-07 21:46:14
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 83 ms / 2,000 ms
コード長 335 bytes
コンパイル時間 159 ms
コンパイル使用メモリ 82,596 KB
実行使用メモリ 96,384 KB
最終ジャッジ日時 2024-06-07 21:46:17
合計ジャッジ時間 2,755 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 34 ms
51,584 KB
testcase_01 AC 34 ms
52,096 KB
testcase_02 AC 33 ms
51,840 KB
testcase_03 AC 33 ms
51,584 KB
testcase_04 AC 37 ms
51,712 KB
testcase_05 AC 33 ms
52,096 KB
testcase_06 AC 34 ms
52,096 KB
testcase_07 AC 34 ms
51,840 KB
testcase_08 AC 35 ms
51,456 KB
testcase_09 AC 57 ms
77,440 KB
testcase_10 AC 58 ms
77,184 KB
testcase_11 AC 58 ms
76,928 KB
testcase_12 AC 82 ms
96,384 KB
testcase_13 AC 81 ms
91,520 KB
testcase_14 AC 83 ms
92,800 KB
testcase_15 AC 79 ms
91,776 KB
testcase_16 AC 47 ms
63,360 KB
testcase_17 AC 81 ms
92,928 KB
testcase_18 AC 68 ms
82,304 KB
testcase_19 AC 67 ms
81,152 KB
testcase_20 AC 52 ms
68,224 KB
testcase_21 AC 51 ms
66,176 KB
testcase_22 AC 63 ms
79,232 KB
testcase_23 AC 67 ms
80,128 KB
testcase_24 AC 68 ms
82,816 KB
testcase_25 AC 82 ms
92,544 KB
testcase_26 AC 80 ms
89,728 KB
testcase_27 AC 63 ms
75,776 KB
testcase_28 AC 50 ms
66,048 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

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

d = {}
cnt_zero = 0

for a in A:
    if a == 0:
        cnt_zero += 1
    else:
        if a in d:
            d[a] += 1
        else:
            d[a] = 1

m = 0
for k, v in d.items():
    m = max(m, v)

if m + cnt_zero >= K:
    print('Yes')
else:
    print('No')
0