結果
| 問題 | No.1692 Expectations |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-09-26 10:19:07 |
| 言語 | PyPy3 (7.3.23 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 74 ms / 2,000 ms |
| + 861µs | |
| コード長 | 371 bytes |
| 記録 | |
| コンパイル時間 | 65 ms |
| コンパイル使用メモリ | 81,700 KB |
| 実行使用メモリ | 142,892 KB |
| 最終ジャッジ日時 | 2026-09-26 10:19:11 |
| 合計ジャッジ時間 | 2,869 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 20 |
ソースコード
N, M = map(int, input().split())
A = list(map(int, input().split()))
from collections import defaultdict
#A = defaultdict(list) # 初期値が [] (空リスト)
B = defaultdict(int) # 初期値に 0 を自動セット
# https://pcnote.henchoko.com/?p=965
for a in A:
B[a] += 1
if N == M and len(B) == 1:
print(len(B), 1)
else:
print(len(B), 0)