hiho week 54 register

Ended

Participants:493

Verdict:Accepted
Score:100 / 100
Submitted:2015-07-11 20:42:07

Lang:G++

Edit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include <cstdio>
#include <algorithm>
#include <vector>
#include <queue>
using namespace std;
int N, M;
long long weigh[20004];
int son[20004], Ecnt;
int Deg[20004];
struct edge
{
    int next, link;
} ed[200005];
inline void Add(int u, int v)
{
    ed[++ Ecnt] = (edge){son[u], v};
    son[u] = Ecnt;
}
int dfn[40004], low[40004], dcnt;
int id[40004];
int Stk[40004], Scnt;
bool instk[40004];
vector<int> Edge[40004], From[40004];
void Tarjan(int u, int p)
{
    dfn[u] = low[u] = ++dcnt;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX