Skip to content

Commit 9d3be8f

Browse files
committed
Fixed error's in pairing heap figure
1 parent b9b0b06 commit 9d3be8f

File tree

6 files changed

+18
-13
lines changed

6 files changed

+18
-13
lines changed

datastruct/heap/other-heaps/create-img.sh

100644100755
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/sh
1+
#!/bin/sh
22

33
CONV="src/fr2dot"
44

@@ -22,7 +22,7 @@ CONV="src/fr2dot"
2222
#$CONV img/pairing-hp.dot "(2, (5, (15)), (4, (13)), (3, (8)), (12), (7), (10), (11), (6), (9, (17), (14, (16))))"
2323
#$CONV img/pairs.dot "(5, (15)), (4, (13)), (3, (8)), (12), (7), (10), (11), (6), (9, (17), (14, (16)))"
2424
#$CONV img/pairs-merge.dot "(4, (5, (15)), (13)), (3, (12), (8)), (7, (10)), (6, (11)), (9, (7), (14, (16)))"
25-
#$CONV img/right-merge-1.dot "(6, (9, (7), (14, (16))), (11))"
26-
#$CONV img/right-merge-2.dot "(6, (7, (10)), (9, (14, (16))), (11))"
27-
#$CONV img/right-merge-3.dot "(3, (6, (7, (10)), (9, (14, (16))), (11)), (12), (8))"
28-
#$CONV img/right-merge-4.dot "(3, (4, (5, (15)), (13)), (6, (7, (10)), (9, (14, (16))), (11)), (12), (8))"
25+
$CONV img/right-merge-1.dot "(6, (9, (17), (14, (16))), (11))"
26+
$CONV img/right-merge-2.dot "(6, (7, (10)), (9, (17), (14, (16))), (11))"
27+
$CONV img/right-merge-3.dot "(3, (6, (7, (10)), (9, (17), (14, (16))), (11)), (12), (8))"
28+
$CONV img/right-merge-4.dot "(3, (4, (5, (15)), (13)), (6, (7, (10)), (9, (17), (14, (16))), (11)), (12), (8))"

datastruct/heap/other-heaps/img/right-merge-1.dot

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
digraph G{
2-
margin="0"
32
node[shape=circle]
43
t6[label="6"];
54
t69[label="9"];
6-
t697[label="7"];
5+
t6917[label="17"];
76
t6914[label="14"];
87
t691416[label="16"];
98
t6914->t691416;
10-
{rank=same t697->t6914[style=invis]}
11-
t69->t697;
9+
{rank=same t6917->t6914[style=invis]}
10+
t69->t6917;
1211
t69->t6914;
1312
t611[label="11"];
1413
{rank=same t69->t611[style=invis]}

datastruct/heap/other-heaps/img/right-merge-2.dot

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
digraph G{
2-
margin="0"
32
node[shape=circle]
43
t6[label="6"];
54
t67[label="7"];
65
t6710[label="10"];
76
t67->t6710;
87
t69[label="9"];
8+
t6917[label="17"];
99
t6914[label="14"];
1010
t691416[label="16"];
1111
t6914->t691416;
12+
{rank=same t6917->t6914[style=invis]}
13+
t69->t6917;
1214
t69->t6914;
1315
t611[label="11"];
1416
{rank=same t67->t69->t611[style=invis]}

datastruct/heap/other-heaps/img/right-merge-3.dot

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
11
digraph G{
2-
margin="0"
32
node[shape=circle]
43
t3[label="3"];
54
t36[label="6"];
65
t367[label="7"];
76
t36710[label="10"];
87
t367->t36710;
98
t369[label="9"];
9+
t36917[label="17"];
1010
t36914[label="14"];
1111
t3691416[label="16"];
1212
t36914->t3691416;
13+
{rank=same t36917->t36914[style=invis]}
14+
t369->t36917;
1315
t369->t36914;
1416
t3611[label="11"];
1517
{rank=same t367->t369->t3611[style=invis]}

datastruct/heap/other-heaps/img/right-merge-4.dot

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
digraph G{
2-
margin="0"
32
node[shape=circle]
43
t3[label="3"];
54
t34[label="4"];
@@ -15,9 +14,12 @@ digraph G{
1514
t36710[label="10"];
1615
t367->t36710;
1716
t369[label="9"];
17+
t36917[label="17"];
1818
t36914[label="14"];
1919
t3691416[label="16"];
2020
t36914->t3691416;
21+
{rank=same t36917->t36914[style=invis]}
22+
t369->t36917;
2123
t369->t36914;
2224
t3611[label="11"];
2325
{rank=same t367->t369->t3611[style=invis]}

others/appendix/list/list-zh-cn.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ \subsection{判空和长度计算}
172172

173173
定义好如何判断列表为空后,就可以计算列表的长度了。在命令式环境中,\textproc{Length}通常实现如下:
174174

175-
\begin{algorithmic}
175+
\begin{algorithmic}[1]
176176
\Function{Length}{L}
177177
\State $n \gets 0$
178178
\While{$L \neq NIL$}

0 commit comments

Comments
 (0)