# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
428371 | jk410 | Unscrambling a Messy Bug (IOI16_messy) | C++17 | 3 ms | 488 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#include "messy.h"
using namespace std;
int N;
vector<int> ans;
void write(int s,int e){
if (s==e)
return;
string t="";
for (int i=0; i<N; i++)
t.push_back('1');
int m=(s+e)>>1;
for (int i=s; i<=e; i++)
t[i]='0';
for (int i=s; i<=m; i++){
t[i]='1';
add_element(t);
t[i]='0';
}
write(s,m);
write(m+1,e);
}
void read(int s,int e,vector<int> v){
if (s==e){
ans[v[0]]=s;
return;
}
vector<int> l,r;
string t="";
for (int i=0; i<N; i++)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |