# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
564744 | 2022-05-19T14:45:59 Z | 1zaid1 | Question (Grader is different from the original contest) (CEOI14_question_grader) | C++14 | 3112 ms | 24148 KB |
#include<bits/stdc++.h> using namespace std; int encode (int n, int x, int y) { int z = (x^y); for (int i = 0; i < 31; i++) { if ((x&(1<<i)) && !(y&(1<<i))) return i+1; } x = __builtin_popcount(x); y = __builtin_popcount(y); for (int i = 0; i < 31; i++) { if (!(x&(1<<i)) && (y&(1<<i))) return i+11; } return 0; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Partially correct | 3112 ms | 24120 KB | Output is partially correct - maxh = 14 |
2 | Partially correct | 3033 ms | 24148 KB | Output is partially correct - maxh = 14 |