# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
135231 | zoooma13 | Parrots (IOI11_parrots) | C++14 | 7 ms | 1576 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 "encoder.h"
#include "encoderlib.h"
using namespace std;
void encode(int N, int M[])
{
vector <bool> bin(8*N ,0);
for(int i=0; i<N; i++)
for(int j=0; j<8; j++)
bin[8*i+j] = M[i]&(1<<j);
for(int i=0; i<bin.size(); i++)
if(bin[i])
send(i);
}
#include "bits/stdc++.h"
#include "decoder.h"
#include "decoderlib.h"
using namespace std;
void decode(int N, int L, int X[])
{
vector <bool> bin(8*N ,0);
for(int i=0; i<L; i++)
bin[X[i]] = 1;
for(int i=0; i<N; i++){
int num = 0;
for(int j=0; j<8; j++)
num |= (1<<j)*bin[8*i+j];
output(num);
}
}
Compilation message (stderr)
# | 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... |