# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
83857 | 2018-11-11T12:39:15 Z | faceless | Question (Grader is different from the original contest) (CEOI14_question_grader) | C++14 | 0 ms | 0 KB |
int numbit (int mask) { int ret = 0; while (mask) { mask -= mask & -mask; ret ++; } return ret; } int to[2000]; int encoder (int n, int x, int y){ int tmp = 1; for (int mask = 0; mask < (1 << 12); mask ++) { if (numbit (mask) == 6) { to[tmp ++] = mask; } } for (int i = 0; i < 12; i++) { if (to[x] & (1 << i) and (to[y] & (1 << i)) == 0) return i + 1; } }