Submission #551366

#TimeUsernameProblemLanguageResultExecution timeMemory
551366AugustinasJucasQuestion (Grader is different from the original contest) (CEOI14_question_grader)C++14
0 / 100
0 ms488 KiB
int encode(int x, int y, int n) { for(int i = 0; i < 10; i++) { int sk = (1 << i); if((x & sk) != (y & sk)) { return i * 2 + ((bool)(x&sk)); } } return -1; }
int decode(int q, int h, int n) { // return "yes", jei q = x, return "no", jei q = y int vl = h & 1; int ind = h / 2; if( ((bool)(q & (1 << ind))) == vl) { return 1; }else { return 0; } }
#Verdict Execution timeMemoryGrader output
Fetching results...