[Tex/LaTex] Are there any (La)TeX Easter Eggs

funknuth

Given Donald Knuth's legendary sense of humor, one cannot help but suppose he would have succumbed to the temptation to add in a "special" command or two that did something unsuspected or unusual just for the fun of it. (And I don't just mean some cute or funny source code comments, but something that actually does something.)

And if not him, then surely someone in the community who has made an extension, document class, package or subversion of TeX, LaTeX, ConTeXt, or a helper program like an editor, etc., decided to have a little fun and throw in an Easter Egg.

Yet, at the moment, I cannot think of a single one. Does anyone know of any?

Best Answer

This is not quite an answer, but I just wrote the following code, that redefines a command to turn its argument by a random angle

Namely, \easteregg\footnote declares all footnotes to rotate their text by a random amount (between -10 and +10 degrees).

\documentclass{article}
\usepackage{rotating}
\usepackage[first=-10,last=10]{lcg}
\makeatletter
\newcommand{\globalrand}{\rand\global\cr@nd\cr@nd}
\makeatother
\newcommand{\easteregg}[1]{%
  \expandafter\let\csname old\string#1\endcsname#1%
  \expandafter\def\expandafter#1\expandafter##\expandafter1\expandafter{%
    \csname old\string#1\endcsname{\protect\globalrand\protect\turnbox{\value{rand}}{##1}\protect\phantom{##1}}}%
}

\easteregg\emph
\easteregg\section

\begin{document}

\section{Test}
\section{More test}
\section{Examples}

\emph{Some} \emph{emphasized} \emph{text}, 
\emph{with} \emph{random} \emph{directions}

\end{document} 
Related Question