摘要: ```cpp #define T 1001 #define S 0 struct Edge{ int nxt,pre,w; }e[500007]; int cntEdge,head[N]; inline void add(int u,int v,int w){ e[++cntEdge] = (Edge){head[u], v, w}, head[u] = cntEdge; } inline... 阅读全文
posted @ 2019-07-15 21:23 邱涵的秘密基地 阅读(153) 评论(0) 推荐(0) 编辑
摘要: ```cpp int n,m,tim; int mp[N][N], sum[N][N]; double ave,dp[N][N][N][N][N]; inline double DP(int a,int b,int c,int d,int t){ if(dp[a][b][c][d][t]) return dp[a][b][c][d][t]; if(t == 1) return sqr((do... 阅读全文
posted @ 2019-07-15 20:18 邱涵的秘密基地 阅读(225) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2019-07-15 15:59 邱涵的秘密基地 阅读(39) 评论(0) 推荐(0) 编辑
摘要: 终末のcode A mater' s BIT... I do not understand at all... Just record it here anyway. 阅读全文
posted @ 2019-07-15 13:24 邱涵的秘密基地 阅读(162) 评论(0) 推荐(0) 编辑
摘要: ```cpp struct LeftTree{ int l,r,val,dis; }t[N]; int fa[N]; inline int Find(int x){ return x == fa[x] ? x : fa[x] = Find(fa[x]); } inline int Merge(int x, int y){ if(!x) return y; if(!y) return x; ... 阅读全文
posted @ 2019-07-14 21:53 邱涵的秘密基地 阅读(132) 评论(0) 推荐(0) 编辑
摘要: TLE but corrct in most cases. AC with an undescriable magic. cpp inline int Find(int x){ return x == fa[x] ? x : fa[x] = Find(fa[x]); } inline int Mer 阅读全文
posted @ 2019-07-14 21:33 邱涵的秘密基地 阅读(145) 评论(0) 推荐(0) 编辑
摘要: ```cpp /* Dear friend, wanna learn CDQ? As a surprice, this code is totally wrong. You may ask, then why you put it on your blog, are you fucking crazy with the fans, isn't it clear you do not have on... 阅读全文
posted @ 2019-07-13 21:00 邱涵的秘密基地 阅读(107) 评论(0) 推荐(0) 编辑
摘要: 一个下午的光阴之死,凶手是细节与手残。 致命的一枪:BIT存权值时: 阅读全文
posted @ 2019-07-13 17:58 邱涵的秘密基地 阅读(141) 评论(0) 推荐(0) 编辑
摘要: Not difficult, the only problem is how to deal with give 0/1 to the var. Tarjan offers the reverse topological order. For each connected, the earlier 阅读全文
posted @ 2019-07-12 20:57 邱涵的秘密基地 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 没注意边数T了N遍的我真是弱啊 阅读全文
posted @ 2019-07-12 18:10 邱涵的秘密基地 阅读(142) 评论(0) 推荐(0) 编辑