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 "bits/stdc++.h"
#include "Alice.h"
using namespace std;
vector<pair<int, int>> Alice(){
long long x = setN(5000);
vector<pair<int, int>> v;
for(int i = 1; i <= 5000; ++i)
if(i^x)
v.push_back({i, x});
return v;
}
#include "bits/stdc++.h"
#include "Bob.h"
using namespace std;
#define ss second
long long Bob(vector<pair<int, int>> v){
map<int, int> mp;
for(auto &i : v)
mp[i.ss]++;
int mx = -1, answer = -1;
for(auto &i : v)
mx = max(mx, mp[i.ss]);
for(auto &i : v)
if(mx == mp[i.ss]){
answer = i.ss;
break;
}
return answer;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |