QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#470479#1834. Eulerian?GenshinImpactsFaultWA 1ms3744kbC++14601b2024-07-10 14:04:462024-07-10 14:04:47

Judging History

你现在查看的是最新测评结果

  • [2024-07-10 14:04:47]
  • 评测
  • 测评结果:WA
  • 用时:1ms
  • 内存:3744kb
  • [2024-07-10 14:04:46]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N = 500010;
mt19937 rnd(chrono::system_clock::now().time_since_epoch().count());
int n;
int a[N];

int main() {
	ios::sync_with_stdio(0); cin.tie(nullptr);
	cin >> n;
	for(int i = 1; i <= n; i++) a[i] = i;
	for(int i = 1; i <= 60; i++) {
		shuffle(a + 1, a + n + 1, rnd);
		cout << "? " << (n + 1) / 2;
		for(int j = 1; j <= (n + 1) / 2; j++) cout << " " << a[j];
		cout << endl;
		int x; cin >> x;
		if(x % 2) {
			cout << "! NO" << endl;
			return 0;
		}
	}
	cout << "! YES" << endl;
	return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3660kb

input:

3
1

output:

? 2 2 3
! NO

result:

ok correct

Test #2:

score: -100
Wrong Answer
time: 1ms
memory: 3744kb

input:

3
1

output:

? 2 1 2
! NO

result:

wrong answer the participant answered wrong