제출 #1245072

#제출 시각아이디문제언어결과실행 시간메모리
1245072repmannQuestion (Grader is different from the original contest) (CEOI14_question_grader)C++20
0 / 100
1 ms320 KiB
static int B[925];
inline void Pre()
{
  for(int i = 1, j = 0; i < 4096; i++)
  {
    if(__builtin_popcount(i) != 6) continue;
    B[++j] = i;
  }
  return;
}
int encode(int n, int x, int y)
{
  for(int i = 0; i < 12; i++) if((B[x] & (1 << i)) && !(B[y] & (1 << i))) return i + 1;
}
static int B[925];
inline void Pre()
{
  for(int i = 1, j = 0; i < 4096; i++)
  {
    if(__builtin_popcount(i) != 6) continue;
    B[++j] = i;
  }
  return;
}
int decode(int n, int q, int h)
{
  return bool(B[q] & (1 << (h - 1)));
}

컴파일 시 표준 에러 (stderr) 메시지

# 1번째 컴파일 단계

encoder.cpp: In function 'int encode(int, int, int)':
encoder.cpp:14:1: warning: control reaches end of non-void function [-Wreturn-type]
   14 | }
      | ^
#Verdict Execution timeMemoryGrader output
Fetching results...