제출 #1232071

#제출 시각아이디문제언어결과실행 시간메모리
1232071jellybean앵무새 (IOI11_parrots)C++20
81 / 100
2 ms840 KiB
#include "encoder.h" #include "encoderlib.h" #include <bits/stdc++.h> using namespace std; //#define int long long #define pb push_back #define fi first #define se second #define dd(x) cout<<#x<<" is "<<x<<endl; #define dd2(x,y) cout<<#x<<" is "<<x<<" "<<#y<<" is "<<y<<endl; typedef long long ll; typedef pair<ll,ll> pii; void encode(int N, int M[]){ int n = N; for(int i=0; i<n; i++){ int x = M[i]; for(int j=0; j<8; j++){ if(x&(1<<j)) send(i*8+j); } } }
#include "decoder.h" #include "decoderlib.h" #include <bits/stdc++.h> using namespace std; //#define int long long #define pb push_back #define fi first #define se second #define dd(x) cout<<#x<<" is "<<x<<endl; #define dd2(x,y) cout<<#x<<" is "<<x<<" "<<#y<<" is "<<y<<endl; typedef long long ll; typedef pair<ll,ll> pii; void decode(int N, int L, int X[]){ int n=N,l=L; int ans[n]={}; for(int i=0; i<l; i++){ int x=X[i]; int id = x/8, pos = x%8; ans[id] += (1<<pos); } for(int i=0; i<n; i++) output(ans[i]); }
#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...