#include<bits/stdc++.h>
#include "highway.h"
using namespace std;
#define ll long long
#define pb push_back
#define ff first
#define ss second
#define all(s) s.begin(),s.end()
#define rall(s) s.rbegin(),s.rend()
void find_pair(int n,vector<int>u,vector<int>v,int A, int B){
int m=u.size();
vector<int>w(m,0);
vector<pair<int,int>>adj[n];
for(int i=0;i<m;i++){
adj[u[i]].pb({v[i],i});
adj[v[i]].pb({u[i],i});
}
ll C=ask(w);
for(int t=1;t<n;t++){
for(auto [_,i]:adj[t]){
w[i]=1;
}
ll cost=ask(w);
if(cost==C-A+B){
answer(0,t);
return;
}
}
return;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
428 KB |
Output is incorrect: answered not exactly once. |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
2 ms |
344 KB |
Execution killed with signal 13 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
8 ms |
1176 KB |
Execution killed with signal 13 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
344 KB |
Execution killed with signal 13 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
12 ms |
1248 KB |
Execution killed with signal 13 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
10 ms |
1248 KB |
Execution killed with signal 13 |
2 |
Halted |
0 ms |
0 KB |
- |