-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathham.ch
112 lines (93 loc) · 1.75 KB
/
ham.ch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
Limbo.
@x l.1
\datethis
@s try x
@y
\datethis
\def\title{HAM}
@z
Section 1.
@x l.15
@d deg u.I
@y
@d deg u.I
@-deg@>
@$deg {HAM}1 =\|u.\|I@>
@%
@$u {GB\_\,GRAPH}9 \&{util}@>
@z
@x l.21
main(int argc,char *argv[])
@y
@#@;@q Fix a bug in CWEB/CTWILL 4.3 @>
int main(int argc,char *argv[])
@z
@x l.33
for (v=g->vertices;v<g->vertices+g->n;v++) printf(" %d",v->deg);
@y
for (v=g->vertices;v<g->vertices+g->n;v++) printf(" %ld",v->deg);
@z
@x l.36
printf("The minimum degree is %d (vertex %s)!\n",x->deg,x->name);
@y
printf("The minimum degree is %ld (vertex %s)!\n",x->deg,x->name);
@z
@x l.46
for (v=g->vertices;v<g->vertices+g->n;v++) printf(" %d",v->deg);
@y
for (v=g->vertices;v<g->vertices+g->n;v++) printf(" %ld",v->deg);
@z
Section 2.
@x l.50
@ @<Process the command line, inputting the graph@>=
@y
@r @ @<Process the command line, inputting the graph@>=
@z
Section 3.
@x l.58
@ Vertices that have already appeared in the path are ``taken,'' and
@y
@ Vertices that have already appeared in the path are ``taken,'' and
@-taken@>
@$taken {HAM}3 =\|v.\|I@>
@%
@$v {HAM}1 \&{register} \&{Vertex} ${}{*}{}$@>
@$v {GB\_\,GRAPH}9 \&{util}@>
@$I {GB\_\,GRAPH}8 \&{long}@>
@z
Section 4.
@x l.85
I may learn my lesson.
@y
I may learn my lesson.
@-k@>
@-vert@>
@-ark@>
@$vert {HAM}4 =\|w.\|V@>
@$ark {HAM}4 =\|x.\|A@>
@%
@$w {GB\_\,GRAPH}9 \&{util}@>
@$x {GB\_\,GRAPH}9 \&{util}@>
@$x {HAM}1 \&{register} \&{Vertex} ${}{*}{}$@>
@z
@x l.92
x->taken=1;@+t->vert=x;
@y
x->taken=1;@+t->vert=x;@+
@z
@x l.97
try: @<Look at edge |a| and its successors, advancing if it is a valid move@>;
@y
try_next: @<Look at edge |a| and its successors, advancing if it is a valid move@>;
@z
Section 8.
@x l.148
goto try;
@y
goto try_next;
@z
Section 10.
@x l.163
@*Index.
@y
@z