<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
\newbox\indexbox
\newbox\leftcol
\newbox\rightcol
\newbox\indexintro

\splittopskip=0pt
\dimpuba=\vsize  \advance\dimpuba by -10pt

\def\firstpage{\setbox\leftcol=\vsplit\indexbox to \dimpube
   \setbox\rightcol=\vsplit\indexbox to \dimpube
   \line{\vtop{\vskip\splittopskip\unvbox\leftcol}\hfil
      \vtop{\unvbox\rightcol}}%
}

\def\fullpage{\setbox\leftcol=\vsplit\indexbox to \dimpuba
   \setbox\rightcol=\vsplit\indexbox to \dimpuba
   \line{\vtop{\vskip\splittopskip\unvbox\leftcol}\hfil
      \vtop{\unvbox\rightcol}}\vfil\break}

\def\lastpage{\setbox\leftcol=\vsplit\indexbox to .5\ht\indexbox
   \setbox\rightcol=\vsplit\indexbox to .5\ht\indexbox
   \line{\vtop{\vskip\splittopskip\unvbox\leftcol}\hfil
      \vtop{\unvbox\rightcol}}\vfil}

\def\makeindex#1#2{%
   \setbox\indexbox=\vbox{\parskip=0pt
      \everypar={\hangindent=1em \hangafter=1}%
      \linepenalty=200 \hsize=.45\hsize \rightskip=0pt plus 1em
      \parindent=0pt
      \obeylines \input #1 }%
   \dimpube=#2
   \begingroup
   \vbadness=10000
   \firstpage
   \loop \ifdim\ht\indexbox&gt;2\dimpuba \fullpage \repeat
   \lastpage
   \endgroup
}


</pre></body></html>