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[]){
for(int i = 0; i < n; i++)
for(int j = 0; j < 8; j++)
send((i << 4) | (j << 1) | (bool)(m[i] & (1 << j)));
}
#include <bits/stdc++.h>
#include "decoder.h"
#include "decoderlib.h"
using namespace std;
void decode(int n, int l, int x[]){
sort(x, x + l);
for(int i = 0; i < l; i += 8){
int cur = 0;
for(int j = 0; j < 8; j++)
cur |= ((x[i + j] & 1) << j);
output(cur);
}
}
# | 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... |