#include <bits/stdc++.h>
#include "Alice.h"
using namespace std;
vector<pair<int,int>> Alice(){
long long x = setN(5000);
vector<pair<int,int>> G;
for(int i=2;i<=5000;i++) G.emplace_back(x%(i-1)+1,i);
return G;
}
#include <bits/stdc++.h>
#include "Bob.h"
using namespace std;
long long Bob(vector<pair<int,int>> V){
long long ans=0,L=1;
for(auto [x,y]:V){
x--;y--;
while(ans%y!=x) ans+=L;
L*=y/__gcd((long long)y,L);
}
return ans;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |