# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
481301 | unknownnnn | Parrots (IOI11_parrots) | C++14 | 0 ms | 0 KiB |
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 "encoder.h"
#include "encoderlib.h"
#include <iostream>
using namespace std;
void encode(int n,int m[])
{
int j=0;
for(int i=0 ; i<n ; i++)
{
m[i]=(m[i]+j);
j+=2;
}
for(int i=0 ; i<n ; i++)
{
send(m[i]);
}
}
#include "encoder.h"
#include "encoderlib.h"
#include <iostream>
using namespace std;
void decode(int n, int l, int m[])
{
int niza[n];
for(int i=0 ; i<l ; i++)
{
int pozicija=m[i]/2;
novaniza[pozicija]=m[i]%2;
}
for(int i=0 ; i<n ; i++)
{
output(novaniza[i]);
}
}