Submission #937877

# Submission time Handle Problem Language Result Execution time Memory
937877 2024-03-04T15:54:45 Z anton Ancient Machine 2 (JOI23_ancient2) C++17
10 / 100
182 ms 1580 KB
#include "ancient2.h"
#include<bits/stdc++.h>

using namespace std;



int mQuery(int m, vector<int>&a, vector<int>&b){
  cout<<m<<endl;
  for(auto e: a){
    cout<<e<<" ";
  }
  cout<<endl;
  for(auto e: b){
    cout<<e<<" ";
  }
  cout<<endl;
  int r= Query(m, a, b);
  cout<<"res "<<r<<endl;
  return r;
}
std::string Solve(int N) {
  
  int n= N;
  string s;
  for(int i = 0; i<n; i++){
    vector<int> a, b;
    for(int j =0; j<i; j++){
      a.push_back(j+1);
      b.push_back(j+1);
    }
    a.push_back(i+2);
    a.push_back(i+1);
    b.push_back(i+1);
    b.push_back(i+2);
    for(int j =i+2; j<n+2; j++){
      a.push_back((j+1)%(n+2));
      b.push_back((j+1)%(n+2));
    }
    int r=  Query(a.size(), a, b);
    if(r==n+1){
      s.push_back('0');
    }
    else{
      s.push_back('1');
    }
    //cout<<s<<endl;
  }
  return s;
}
# Verdict Execution time Memory Grader output
1 Partially correct 155 ms 804 KB Output is partially correct
2 Partially correct 173 ms 1136 KB Output is partially correct
3 Partially correct 168 ms 1048 KB Output is partially correct
4 Partially correct 150 ms 1540 KB Output is partially correct
5 Partially correct 162 ms 1272 KB Output is partially correct
6 Partially correct 171 ms 1096 KB Output is partially correct
7 Partially correct 147 ms 1128 KB Output is partially correct
8 Partially correct 148 ms 1152 KB Output is partially correct
9 Partially correct 151 ms 1124 KB Output is partially correct
10 Partially correct 146 ms 1068 KB Output is partially correct
11 Partially correct 157 ms 1420 KB Output is partially correct
12 Partially correct 146 ms 1004 KB Output is partially correct
13 Partially correct 145 ms 1364 KB Output is partially correct
14 Partially correct 148 ms 1012 KB Output is partially correct
15 Partially correct 145 ms 1224 KB Output is partially correct
16 Partially correct 153 ms 1336 KB Output is partially correct
17 Partially correct 145 ms 1056 KB Output is partially correct
18 Partially correct 148 ms 1472 KB Output is partially correct
19 Partially correct 148 ms 1312 KB Output is partially correct
20 Partially correct 148 ms 1064 KB Output is partially correct
21 Partially correct 151 ms 1204 KB Output is partially correct
22 Partially correct 148 ms 756 KB Output is partially correct
23 Partially correct 146 ms 940 KB Output is partially correct
24 Partially correct 147 ms 1356 KB Output is partially correct
25 Partially correct 145 ms 1412 KB Output is partially correct
26 Partially correct 153 ms 1488 KB Output is partially correct
27 Partially correct 149 ms 1088 KB Output is partially correct
28 Partially correct 145 ms 1264 KB Output is partially correct
29 Partially correct 148 ms 1484 KB Output is partially correct
30 Partially correct 152 ms 1408 KB Output is partially correct
31 Partially correct 147 ms 1132 KB Output is partially correct
32 Partially correct 150 ms 1128 KB Output is partially correct
33 Partially correct 151 ms 1556 KB Output is partially correct
34 Partially correct 145 ms 1184 KB Output is partially correct
35 Partially correct 149 ms 1320 KB Output is partially correct
36 Partially correct 147 ms 1076 KB Output is partially correct
37 Partially correct 150 ms 1144 KB Output is partially correct
38 Partially correct 150 ms 1200 KB Output is partially correct
39 Partially correct 151 ms 1380 KB Output is partially correct
40 Partially correct 151 ms 1304 KB Output is partially correct
41 Partially correct 152 ms 1580 KB Output is partially correct
42 Partially correct 148 ms 1160 KB Output is partially correct
43 Partially correct 148 ms 1268 KB Output is partially correct
44 Partially correct 150 ms 1524 KB Output is partially correct
45 Partially correct 158 ms 1292 KB Output is partially correct
46 Partially correct 152 ms 1344 KB Output is partially correct
47 Partially correct 160 ms 1308 KB Output is partially correct
48 Partially correct 161 ms 1348 KB Output is partially correct
49 Partially correct 156 ms 1068 KB Output is partially correct
50 Partially correct 158 ms 1152 KB Output is partially correct
51 Partially correct 169 ms 1352 KB Output is partially correct
52 Partially correct 182 ms 1124 KB Output is partially correct
53 Partially correct 168 ms 1228 KB Output is partially correct
54 Partially correct 170 ms 1020 KB Output is partially correct
55 Partially correct 162 ms 1172 KB Output is partially correct
56 Partially correct 161 ms 1212 KB Output is partially correct
57 Partially correct 162 ms 924 KB Output is partially correct
58 Partially correct 155 ms 1044 KB Output is partially correct
59 Partially correct 164 ms 1152 KB Output is partially correct
60 Partially correct 157 ms 1256 KB Output is partially correct
61 Partially correct 157 ms 1092 KB Output is partially correct
62 Partially correct 165 ms 1012 KB Output is partially correct
63 Partially correct 167 ms 1024 KB Output is partially correct