# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
395327 | ankhbayar06 | 자매 도시 (APIO20_swap) | C++14 | 2088 ms | 7296 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "swap.h"
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define pb push_back
#define F first
#define S second
#define mk make_pair
int i,n,m,b[300000],t[300000],sz[300000],a[300000],x,y;
pair<int , pair<int , int>> p[300000];
void init(int N, int M, vector <int> U, vector <int> V, vector <int> W) {
n = N;
m = M;
for (i=0 ; i<m ; i++){
p[i].first=W[i];
p[i].second.first=U[i];
p[i].second.second=V[i];
}
sort (p,p+m);
}
int fnd(int xx){
if(xx==t[xx]){
return xx;
}
else return t[xx]=fnd(t[xx]);
}
void negtge( int x , int y){
x=fnd(x);
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |