제출 #1252135

#제출 시각아이디문제언어결과실행 시간메모리
1252135lambd47앵무새 (IOI11_parrots)C++20
0 / 100
1 ms840 KiB
#include <bits/stdc++.h> using namespace std; #include "encoder.h" #include "encoderlib.h" #define L(i,j,k) for(int i=(j);i<=(k);i++) #define all(v) (v).begin(),(v).end() #define sz(v) ((int)v.size()) void encode(int n, int vec[]) { int at=0; L(i,0,n-1){ L(j,0,7){ if(vec[i]&&(1<<j))at++; send(at); } } }
#include <bits/stdc++.h> #include "decoder.h" #include "decoderlib.h" using namespace std; #define L(i,j,k) for(int i=(j);i<=(k);i++) #define all(v) (v).begin(),(v).end() #define sz(v) ((int)v.size()) void decode(int n, int l, int vec[]) { sort(vec,vec+l); int lst=0; for(int i=0;i<l;i+=8){ int at=0; L(j,i,i+7){ at+=(vec[j]-lst)*(1<<(j-i)); lst=vec[j]; } output(at); } }
#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...