This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <vector>
#include <utility>
long long setN(int n);
std::vector<std::pair<int,int>> Alice()
{
std::vector<std::pair<int,int>>v;
long long x=setN(5000);
for(int i=2;i<=5000;++i)
v.push_back({x%(i-1)+1,i});
return v;
}
#include <vector>
#include <utility>
long long Bob(std::vector<std::pair<int,int>> V)
{
int n=V.size();
for(int i=V[n-1].first-1;;i+=V[n-1].second-1)
{
std::pair<int,int>q;
for(int j=0;j<n;++j)
{
q=V[j];
if(j==n-1)
return i;
if(i%(V[j].second-1)!=V[j].first-1)
break;
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |