Submission #364983

#TimeUsernameProblemLanguageResultExecution timeMemory
364983denkendoemeerCup of Jamshid (IOI17_cup)C++14
100 / 100
1 ms364 KiB
#include<bits/stdc++.h> #include "cup.h" using namespace std; vector<int> find_cup() { int aux=-1e9,ans,numx=0,numy; int i; ans=ask_shahrasb(aux,aux); for(i=0;i<31;i++){ int aux2=ask_shahrasb(aux+(1<<i),aux); if (aux2==(ans^(1<<i))) numx+=(1<<i); } numy=ans^numx; vector<int>rez; rez.push_back(aux+numx); rez.push_back(aux+numy); return rez; }
#Verdict Execution timeMemoryGrader output
Fetching results...