OSDN Git Service
(root)
/
oi-wiki
/
main.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d121280
)
Update shortest-path.md
author
peterlits zo
<peterlitszo@outlook.com>
Thu, 28 Jan 2021 04:24:13 +0000
(12:24 +0800)
committer
GitHub
<noreply@github.com>
Thu, 28 Jan 2021 04:24:13 +0000
(12:24 +0800)
docs/graph/shortest-path.md
patch
|
blob
|
history
diff --git
a/docs/graph/shortest-path.md
b/docs/graph/shortest-path.md
index
15115fd
..
1fb0db9
100644
(file)
--- a/
docs/graph/shortest-path.md
+++ b/
docs/graph/shortest-path.md
@@
-273,8
+273,8
@@
for (i = 1; i <= n; i++) {
或者说一个 `C++` 代码:
```C++
-vector<vector<
Point>> Ps;
// 图的邻接矩阵
-vector<LL> dist; // min_len 的运行结果存储位置
+vector<vector<
LL>> Ps;
// 图的邻接矩阵
+vector<LL> dist;
// min_len 的运行结果存储位置
// i: 源点在点集中的下标
void min_len(size_t i) {
@@
-286,7
+286,7
@@
void min_len(size_t i) {
dist[i] = 0;
// 初始化小根堆
- priority
<Pair, vector<Pair>, greater<Pair>> Q;
// 小根堆
+ priority
_queue<Pair, vector<Pair>, greater<Pair>> Q;
// 小根堆
Q.push(Pair(0, i));
while (!Q.empty()) {