제출 #795011

#제출 시각UTC-0아이디문제언어결과실행 시간메모리
7950112023-07-27 05:11:32khshg앵무새 (IOI11_parrots)C++14
0 / 100
4 ms1220 KiB
#include "encoder.h"
#include "encoderlib.h"
#include <bits/stdc++.h>
using namespace std;
void encode(int N, int M[]) {
vector<int> go;
int cnt = 0;
for(int i = 0; i < N; ++i) {
for(int j = 0; j < 4; ++j) {
int B = (M[i] >> (6 - 2 * j));
B &= 3;
cnt += B;
}
}
if(N * 2 * 3 <= cnt) {
for(int i = 0; i < 4; ++i) send(0);
for(int i = 0; i < N; ++i) {
for(int j = 0; j < 4; ++j) {
int B = (M[i] >> (6 - 2 * j));
B &= 3;
B = 3 - B;
while(B--) send((i << 2) + j);
}
}
return;
}
for(int i = 0; i < N; ++i) {
for(int j = 0; j < 4; ++j) {
int B = (M[i] >> (6 - 2 * j));
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

컴파일 시 표준 에러 (stderr) 메시지

decoder.cpp: In function 'void decode(int, int, int*)':
decoder.cpp:14:37: warning: suggest parentheses around '-' in operand of '&' [-Wparentheses]
   14 |   ans[(X[i] >> 2)] -= (1 << (2 * (3 - X[i] & 3)));
      |                                   ~~^~~~~~
#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...