常规的最短路问题为: (1)询问
1
−
n
1-n
1−n路径长度的最小值 (2)
d
i
s
[
x
]
dis[x]
dis[x]表示
1
−
x
1-x
1−x的距离 (3)松弛条件为
d
i
s
[
y
]
>
d
i
s
[
x
]
+
w
dis[y]>dis[x]+w
dis[y]>dis[x]+w
本题为最短路变形问题: (1)询问
1
−
n
1-n
1−n经过的边权最大值的最小值 (2)
d
i
s
[
x
]
dis[x]
dis[x]表示
1
−
x
1-x
1−x边权最大值的最小值 (3)松弛条件为
d
i
s
[
y
]
>
m
a
x
(
d
i
s
[
x
]
,
w
)
dis[y]>max(dis[x],w)
dis[y]>max(dis[x],w)