黄学骏
黄学骏
全部文章
题解
归档
标签
去牛客网
登录
/
注册
黄学骏的博客
全部文章
/ 题解
(共8篇)
题解 | #PUBG#
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int ,int > PII; const int N = 110; int n; int g[N][...
最短路
2022-09-15
1
330
题解 | #Travel#
#include <bits/stdc++.h> using namespace std; typedef long long ll; const int N = 525020,M = 3 * N; int n,m; ll a[N*2],sum[N*2]; ll e[M],...
最短路
2022-09-05
2
466
题解 | #Chocolate Giving#
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int ,int> PII; const int N = 200010; int p,n,m; int...
最短路
2022-09-05
2
268
题解 | #[USACO 2010 Dec G]Big Macs Around the World#
#include <bits/stdc++.h> using namespace std; typedef pair<double,double> PII; typedef double ld; const int N = 350010; int n,m,idx,A...
最短路
2022-08-06
1
312
题解 | #[USACO 2010 Dec S]Apple Delivery#
#include <bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N = 400100; int C,P,PB,PA1,PA2; int e[N],w[N],ne[N]...
最短路
2022-08-06
1
361
题解 | #New Game!#
/* 建立两个虚拟远点 0 和 n+1 ,分别为 c1 和 c2 的虚拟远点 但是 不用看了 数据太水了 */ #include <bits/stdc++.h> using namespace std; typedef double ld; const int N = 1010;...
最短路
2022-08-05
1
426
题解 | #武#
#include <bits/stdc++.h> using namespace std; const int N = 1e6+10, M = N*2; typedef pair<int,int> PII; int n,p,k; int e[M],ne[M],h[N]...
最短路
2022-08-05
2
405
题解 | #最短路计数#
// Dijstra 算法 和 BFS 求最短路满足拓扑序 每个点只入队一次 而SPFA算法不满足 一个点可能入队多次 #include <bits/stdc++.h> using namespace std; const int N = 400010 , mod = 100003;...
最短路
2022-08-05
1
363