Submission #136891

#TimeUsernameProblemLanguageResultExecution timeMemory
136891zoooma13Question (Grader is different from the original contest) (CEOI14_question_grader)C++14
27 / 100
1605 ms127016 KiB
#include "bits/stdc++.h" using namespace std; int encode(int n, int x, int y){ int diff = (x^y); int lst_bit = log2((diff)&(-diff)); return (bool(x&(1<<lst_bit))*10 + lst_bit+1); }
#include "bits/stdc++.h" using namespace std; int decode(int n, int q, int h){ int lst_bit = (h-1)%10; bool b = q&(1<<lst_bit); return (b && h>10) || (!b && h<=10); }
#Verdict Execution timeMemoryGrader output
Fetching results...