QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#654975 | #1834. Eulerian? | jiangzhihui# | WA | 2ms | 3708kb | C++20 | 854b | 2024-10-18 23:29:32 | 2024-10-18 23:29:33 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
const int N=1919810;
typedef long long ll;
typedef pair<ll,ll> PII;
int n,m,k;
int a[N],b[N];
char s[N];
vector<PII> e[N];
int d[N];
bool tf[N];
int query(vector<int> &v){
cout<<v.size()<<" ";
for(auto x:v) cout<<x<<" ";
cout<<endl;
int x;
cin>>x;
return x;
}
mt19937 rnd(time(0));
int main(){
ios::sync_with_stdio(0);
cin.tie(0);
cin>>n;
vector<int> v;
for(int i=1;i<=n;i++) v.push_back(i);
ll tot=query(v);
for(int i=1;i<=59;i++){
vector<int> v;
int t1=rnd()%n+1;
for(int j=1;j<=n;j++){
if(j==t1) continue;
v.push_back(j);
}
if((tot-query(v)&1)){
cout<<"! NO"<<endl;
return 0;
}
}
cout<<"! YES"<<endl;
}
详细
Test #1:
score: 0
Wrong Answer
time: 2ms
memory: 3708kb
input:
3 -1
output:
3 1 2 3 2 2 3
result:
wrong output format Unexpected end of file - token expected