aboutsummaryrefslogtreecommitdiff
path: root/src/input/heap.input.pamphlet
diff options
context:
space:
mode:
Diffstat (limited to 'src/input/heap.input.pamphlet')
-rw-r--r--src/input/heap.input.pamphlet30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/input/heap.input.pamphlet b/src/input/heap.input.pamphlet
new file mode 100644
index 00000000..c65f5caf
--- /dev/null
+++ b/src/input/heap.input.pamphlet
@@ -0,0 +1,30 @@
+\documentclass{article}
+\usepackage{axiom}
+\begin{document}
+\title{\$SPAD/src/input HEAP.input}
+\author{The Axiom Team}
+\maketitle
+\begin{abstract}
+\end{abstract}
+\eject
+\tableofcontents
+\eject
+<<*>>=
+
+-- Input generated from HeapXmpPage
+)clear all
+
+h := heap [-4,9,11,2,7,-7]
+insert!(3,h)
+extract! h
+h
+[extract!(h) while not empty?(h)]
+heapsort(x) == (empty? x => []; cons(extract!(x),heapsort x))
+h1 := heap [17,-4,9,-11,2,7,-7]
+heapsort h1
+@
+\eject
+\begin{thebibliography}{99}
+\bibitem{1} nothing
+\end{thebibliography}
+\end{document}