Submission #229270

#TimeUsernameProblemLanguageResultExecution timeMemory
229270super_j6질문 (CEOI14_question_grader)C++14
Compilation error
0 ms0 KiB
int a[920]; int encode(int n, int x, int y){ x--, y--; if(!a[0]) for(int i = 0, j = 0; i < n; i++, j++){ while(__builtin_popcount(j) != 6) j++; a[i] = j; } return __lg(a[x] & (a[x] ^ a[y])) + 1; }
int a[920]; int decode(int n, int x, int y){ x--, y--; if(!a[0]) for(int i = 0, j = 0; i < n; i++, j++){ while(__builtin_popcount(j) != 6) j++; a[i] = j; } return (a[x] >> y) & 1; }

Compilation message (stderr)

encoder.cpp: In function 'int encode(int, int, int)':
encoder.cpp:8:12: error: '__lg' was not declared in this scope
     return __lg(a[x] & (a[x] ^ a[y])) + 1;
            ^~~~
encoder.cpp:8:12: note: suggested alternative: '__k8'
     return __lg(a[x] & (a[x] ^ a[y])) + 1;
            ^~~~
            __k8