Submission #41110

# Submission time Handle Problem Language Result Execution time Memory
41110 2018-02-12T20:06:44 Z hsb154 Parrots (IOI11_parrots) C++14
17 / 100
5 ms 2000 KB
#include "encoder.h"
#include "encoderlib.h"

void encode(int N, int M[])
{
	for (int i = 0; i < N; i++) {
		int temp = 0;
		temp = temp | (i << 3);
		temp = temp | M[i];
		send(temp);
	}
}
#include "decoder.h"
#include "decoderlib.h"

void decode(int N, int L, int X[])
{
	for (int i = 0; i < N; i++) {
		for (int j = 0; j < L; j++) {
			if((X[j]>>3)==i)
				output(X[j]&7);
		}
	}
}
# Verdict Execution time Memory Grader output
1 Correct 4 ms 752 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 1592 KB Error : Output length must be N
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 1784 KB Error : Output length must be N
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 1912 KB Error : Output length must be N
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 5 ms 2000 KB Error : Output length must be N
2 Incorrect 5 ms 2000 KB Error : Output is wrong
3 Incorrect 4 ms 2000 KB Error : Bad encoded integer
4 Incorrect 4 ms 2000 KB Error : Bad encoded integer
5 Incorrect 4 ms 2000 KB Error : Bad encoded integer
6 Incorrect 4 ms 2000 KB Error : Bad encoded integer
7 Incorrect 4 ms 2000 KB Error : Bad encoded integer