Submission #809413

#TimeUsernameProblemLanguageResultExecution timeMemory
809413hgmhcParrots (IOI11_parrots)C++17
81 / 100
4 ms1160 KiB
#include "encoder.h" #include "encoderlib.h" #include <bits/stdc++.h> using namespace std; void encode(int n, int a[]) { for (int i = 0; i < n; ++i) { // n:5bit, m:8bit, s:8bit // j:3bit * 10 for (int j = 0; j < 8; ++j) { if (a[i]>>j&1) send((i<<3)|j); } } }
#include "decoder.h" #include "decoderlib.h" #include <bits/stdc++.h> using namespace std; const int N = 32; void decode(int n, int l, int x[]) { int ans[N]{}; for (int k = 0; k < l; ++k) { int i = x[k]>>3; int j = x[k]&0b111; ans[i] |= 1<<j; } for (int i = 0; i < n; ++i) output(ans[i]); } // g++-13 grader.cpp encoder.cpp decoder.cpp -o par && ./par < grader.in.1
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...