#include "encoder.h"
#include "encoderlib.h"
void encode (int N, int M[])
{
for(int i = 0; i < N; i++)
{
if(M[i])
{
send(i);
}
}
}
#include "decoder.h"
#include "decoderlib.h"
int result[9];
void decode (int N, int L, int X[]) {
for(int i = 0; i < N; i++)
{
result[i]=0;
}
for(int i = 0; i < L; i++)
{
result[X[i]]=1;
}
for(int i = 0; i < N; i++)
{
output(result[i]);
}
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
4 ms |
752 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
3 ms |
1736 KB |
Error : Output is wrong |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
4 ms |
1888 KB |
Error : Output is wrong |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
4 ms |
2072 KB |
Error : Output is wrong |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
5 ms |
2136 KB |
Error : Output is wrong |
2 |
Incorrect |
6 ms |
2136 KB |
Error : Output is wrong |
3 |
Incorrect |
6 ms |
2168 KB |
Error : Output is wrong |
4 |
Incorrect |
5 ms |
2200 KB |
Error : Output is wrong |
5 |
Incorrect |
6 ms |
2200 KB |
Error : Output is wrong |
6 |
Incorrect |
5 ms |
2232 KB |
Error : Output is wrong |
7 |
Incorrect |
7 ms |
2272 KB |
Error : Output is wrong |