summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/mi-solns/examples/create-db.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/mi-solns/examples/create-db.tex')
-rw-r--r--macros/latex/contrib/mi-solns/examples/create-db.tex92
1 files changed, 92 insertions, 0 deletions
diff --git a/macros/latex/contrib/mi-solns/examples/create-db.tex b/macros/latex/contrib/mi-solns/examples/create-db.tex
new file mode 100644
index 0000000000..2a55c1e8e8
--- /dev/null
+++ b/macros/latex/contrib/mi-solns/examples/create-db.tex
@@ -0,0 +1,92 @@
+\documentclass{article}
+\usepackage[designiv,forcolorpaper]{web}
+\usepackage{exerquiz}
+
+\usepackage{mi-solns}
+\declSOLOut{poems.lst}
+
+%\copySolnsOff
+
+% This formatting is optional, the purpose of this file is to create
+% the poems.lst file, which is to be input by another file.
+\renewcommand\exlabel{Poet}
+\renewcommand\exlabelformat{{\scshape\exlabel:}}
+\renewcommand\exsllabelformat{\protect\textbf{\exlabelsol\ \currentpoet}}
+\renewcommand\exsllabelformatwp
+ {\protect\textbf{\currentpoet: \currenttitle}}
+\renewcommand\exsectitle{List of \exlabel s and their Poems}
+\partsformat{}
+\def\currentPoet#1{\def\currentpoet{#1}}
+\def\currentTitle#1{\def\currenttitle{#1}}
+\partsitemsep{6pt}
+
+\begin{document}
+
+\currentPoet{Ogden Nash}
+\begin{exercise*}
+\textbf{Ogden Nash}
+\begin{parts}
+\item \currentTitle{First Limerick}\textbf{First Limerick}
+\insExSoln{First Limerick}
+\mrkForIns{First Limerick}
+\begin{solution}[]
+\begin{quote}\obeylines
+An old person of Troy
+Is so prudish and coy
+That it doesn't know yet
+If it's a girl or a boy.
+\end{quote}
+\end{solution}
+
+\item \currentTitle{The Lama}\textbf{The Lama}
+\insExSoln{The Lama}
+\mrkForIns{The Lama}
+\begin{solution}[]
+\begin{quote}\obeylines
+The one-l lama,
+He's a priest,
+The two-l llama,
+He's a beast.
+And I will bet
+A silk pajama
+There isn't any
+Three-l lllama\footnote{\raggedright The author here is referring to a three-alarm fire, called a ``three-alarmer''.}
+\end{quote}
+\end{solution}
+\end{parts}
+\end{exercise*}
+
+\currentPoet{Edward R. Sill}
+\begin{exercise*}
+\textbf{Edward R. Sill}
+\begin{parts}
+\item \currentTitle{Opportunity}\textbf{Opportunity}
+\insExSoln{Opportunity}
+\mrkForIns{Opportunity}
+\begin{solution}[]
+\begin{quote}\obeylines
+This I beheld, or dreamed it in a dream:---
+There spread a cloud of dust along a plain;
+And underneath the cloud, or in it, raged
+A furious battle, and men yelled, and swords
+Shocked upon swords and shields. A prince's banner
+Wavered then staggered backward, hemmed by foes.\vspace{\baselineskip}
+
+A craven hung along the battle's edge,
+And thought, ``Had I a sword of keener steal---
+That blue blade that the king's son bears---but this
+Blunt thing!''---he snapped and flung it from his hand.
+And lowering crept away and left the field.\vspace{\baselineskip}
+
+Then came the king's son, wounded, sore bestead,
+And weaponless, and saw the broken sword,
+Hilt-buried in the dry and trodden sand,
+And ran and snatched it, and with battle-shout,
+Lifted afresh he hewed his enemy down,
+And saved a great cause that heroic day.
+\end{quote}
+\end{solution}
+\end{parts}
+\end{exercise*}
+
+\end{document}