| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1364780 | mayac | Guessing Game (EGOI23_guessinggame) | C++20 | 409 ms | 820 KiB |
#include <bits/stdc++.h>
using namespace std;
using ll=long long;
const ll a=67,b=123,c=10001;
ll n=1e5;
void alice(){
int t=0;
cout<<n<<endl;
for(int i=0;i<n-1;i++){
cin>>t;
cout<<i+1<<endl;
}
}
void bob(){
int t,s1=n,s2=n;
vector<int> vis(n+1,-1);
for(int i=0;i<n;i++){
cin>>t;
if(vis[t]!=-1){
s1=vis[t];
s2=i;
}
vis[t]=i;
}
cout<<s1<<" "<<s2<<endl;
}
int main(){
ll p;
cin>>p>>n;
if(p==1){
alice();
}else{
bob();
}
}| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
