結果
| 問題 |
No.3280 Black-Tailed Gull vs Monster
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-10-16 02:44:14 |
| 言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 147 ms / 2,000 ms |
| コード長 | 505 bytes |
| コンパイル時間 | 3,638 ms |
| コンパイル使用メモリ | 281,052 KB |
| 実行使用メモリ | 10,752 KB |
| 最終ジャッジ日時 | 2025-10-16 02:44:22 |
| 合計ジャッジ時間 | 6,988 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 40 |
ソースコード
#include<bits/stdc++.h>
using namespace std;
using ll=long long;
int main(){
ios::sync_with_stdio(false);
cin.tie(nullptr);
int N,X,Q;
cin>>N>>X>>Q;
int cnt=0;
for(int i=0;i<Q;i++){
int M;
cin>>M;
map<int,int> C;
bool D=0;
for(int j=0;j<M;j++){
int F;
cin>>F;
C[F]++;
if(C[F]==2)D=1;
}
if(C.count(X))cnt+=2;
else if(D)cnt++;
}
cout<<double(cnt)/2.0<<"\n";
}