次短路
单源(即从顶点s到顶点t的最短路):
问题链接:
https://loj.ac/p/10076
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N=2e5+5,inf=0x3f3f3f3f;
int nxt[N],to[N],dis[N];
int head[5005];
int n,m,x,tot;
int d2[5005],d1[5005];
int ans;
struct ..
原创
2021-11-26 17:18:40 ·
382 阅读 ·
0 评论