제출 #478686

#제출 시각UTC-0아이디문제언어결과실행 시간메모리
4786862021-10-08 07:15:19VitaliyFS꿈 (IOI13_dreaming)C++17
0 / 100
21 ms3788 KiB
#include "dreaming.h"
#include <bits/stdc++.h>
#define fr first
#define sc second
using namespace std;
//using namespace __gnu_pbds;
typedef long long ll;
typedef long double ld;
typedef pair<ll, ll> pll;
//typedef tree<ll, null_type, less<ll>, rb_tree_tag, tree_order_statistics_node_update> myset;
const ll DIM = 100007, INF = 2000000000000000007, MOD = 998244353, split = 1000;
ll t, n, m, z, q, nn,mm,kk, par[DIM], di[DIM], cl, cr, f, prev, mid, p, res2, nComp = 0, ans1, ans2, res, mi, pos, pos1, pos2, sum, ct, y, k, tt, x, t1, t2, mi1 = INF, ma1 = -INF, mi2 = INF, ma2 = -INF, v, l = INF, r = -INF, u, w, ma = -INF, id, lx, xd, yd;
bool flag;
pll comp[DIM];
vector<pll> g[DIM];
vector<ll> usedVertex;
bool used[DIM];
void dfs(ll v, ll p = -1, ll dp = 0, ll d = 0) {
usedVertex.push_back(v);
if(d > ma) {ma = max(ma, d); u = v;}
used[v] = 1;
di[v] = dp;
par[v] = p;
for(auto [u, w] : g[v])
 
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...