結果
| 問題 | No.3280 Black-Tailed Gull vs Monster |
| コンテスト | |
| ユーザー |
nhtloc
|
| 提出日時 | 2025-12-04 12:40:16 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 517 ms / 2,000 ms |
| コード長 | 470 bytes |
| 記録 | |
| コンパイル時間 | 172 ms |
| コンパイル使用メモリ | 12,160 KB |
| 実行使用メモリ | 29,824 KB |
| 最終ジャッジ日時 | 2025-12-04 12:40:24 |
| 合計ジャッジ時間 | 7,887 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 40 |
ソースコード
N, X, Q = map(int, input().split())
expected = 0.0
for _ in range(Q):
M = int(input())
F = list(map(int, input().split()))
gull_acted = any(f == X for f in F)
if gull_acted:
expected += 1.0
continue
counts = {}
multiple = False
for f in F:
counts[f] = counts.get(f, 0) + 1
if counts[f] >= 2:
multiple = True
break
if multiple:
expected += 0.5
print(f"{expected:.10f}")
nhtloc