Submission #820625

# Submission time Handle Problem Language Result Execution time Memory
820625 2023-08-11T05:04:58 Z ono_de206 Ancient Machine 2 (JOI23_ancient2) C++17
10 / 100
106 ms 644 KB
#include "ancient2.h"
#include<bits/stdc++.h>
using namespace std;

#define in insert
#define all(x) x.begin(),x.end()
#define pb push_back
#define eb emplace_back
#define ff first
#define ss second

//#define int long long

typedef long long ll;
typedef vector<int> vi;
typedef set<int> si;
typedef multiset<int> msi;
typedef pair<int, int> pii;
typedef vector<pii> vpii;

string Solve(int n) {
	vector<int> a, b;
	string ans = "";
	for(int i = 0; i < n; i++) {
		a.pb(i + 2);
		b.pb(i + 1);
		for(int j = 0; j < 2; j++) {
			a.pb(i + j + 1);
			b.pb(i + j + 1);
		}
		int l = Query((int)a.size(), a, b);
		if(l == i + 2) ans.pb('0');
		else ans.pb('1');
		for(int j = 0; j < 3; j++) {
			a.pop_back();
			b.pop_back();
		}
		a.pb(i + 1);
		b.pb(i + 1);
	}
	return ans;
}
# Verdict Execution time Memory Grader output
1 Partially correct 69 ms 372 KB Output is partially correct
2 Partially correct 75 ms 464 KB Output is partially correct
3 Partially correct 75 ms 368 KB Output is partially correct
4 Partially correct 72 ms 372 KB Output is partially correct
5 Partially correct 75 ms 372 KB Output is partially correct
6 Partially correct 76 ms 360 KB Output is partially correct
7 Partially correct 76 ms 364 KB Output is partially correct
8 Partially correct 83 ms 368 KB Output is partially correct
9 Partially correct 75 ms 488 KB Output is partially correct
10 Partially correct 72 ms 368 KB Output is partially correct
11 Partially correct 76 ms 364 KB Output is partially correct
12 Partially correct 75 ms 364 KB Output is partially correct
13 Partially correct 73 ms 368 KB Output is partially correct
14 Partially correct 81 ms 372 KB Output is partially correct
15 Partially correct 89 ms 492 KB Output is partially correct
16 Partially correct 92 ms 564 KB Output is partially correct
17 Partially correct 87 ms 368 KB Output is partially correct
18 Partially correct 70 ms 360 KB Output is partially correct
19 Partially correct 104 ms 368 KB Output is partially correct
20 Partially correct 76 ms 364 KB Output is partially correct
21 Partially correct 74 ms 368 KB Output is partially correct
22 Partially correct 77 ms 472 KB Output is partially correct
23 Partially correct 78 ms 368 KB Output is partially correct
24 Partially correct 84 ms 364 KB Output is partially correct
25 Partially correct 75 ms 376 KB Output is partially correct
26 Partially correct 73 ms 360 KB Output is partially correct
27 Partially correct 74 ms 364 KB Output is partially correct
28 Partially correct 76 ms 368 KB Output is partially correct
29 Partially correct 75 ms 468 KB Output is partially correct
30 Partially correct 81 ms 644 KB Output is partially correct
31 Partially correct 85 ms 356 KB Output is partially correct
32 Partially correct 73 ms 360 KB Output is partially correct
33 Partially correct 76 ms 496 KB Output is partially correct
34 Partially correct 75 ms 364 KB Output is partially correct
35 Partially correct 75 ms 372 KB Output is partially correct
36 Partially correct 98 ms 488 KB Output is partially correct
37 Partially correct 98 ms 612 KB Output is partially correct
38 Partially correct 78 ms 372 KB Output is partially correct
39 Partially correct 106 ms 328 KB Output is partially correct
40 Partially correct 76 ms 592 KB Output is partially correct
41 Partially correct 72 ms 364 KB Output is partially correct
42 Partially correct 84 ms 360 KB Output is partially correct
43 Partially correct 81 ms 364 KB Output is partially correct
44 Partially correct 74 ms 364 KB Output is partially correct
45 Partially correct 74 ms 372 KB Output is partially correct
46 Partially correct 72 ms 364 KB Output is partially correct
47 Partially correct 79 ms 476 KB Output is partially correct
48 Partially correct 77 ms 372 KB Output is partially correct
49 Partially correct 77 ms 368 KB Output is partially correct
50 Partially correct 70 ms 356 KB Output is partially correct
51 Partially correct 71 ms 472 KB Output is partially correct
52 Partially correct 71 ms 376 KB Output is partially correct
53 Partially correct 74 ms 368 KB Output is partially correct
54 Partially correct 77 ms 368 KB Output is partially correct
55 Partially correct 75 ms 368 KB Output is partially correct
56 Partially correct 74 ms 372 KB Output is partially correct
57 Partially correct 80 ms 400 KB Output is partially correct
58 Partially correct 75 ms 468 KB Output is partially correct
59 Partially correct 84 ms 364 KB Output is partially correct
60 Partially correct 72 ms 364 KB Output is partially correct
61 Partially correct 71 ms 368 KB Output is partially correct
62 Partially correct 73 ms 368 KB Output is partially correct
63 Partially correct 79 ms 372 KB Output is partially correct