Can we think of ways to make TeX behave in funny, surprising, and unexpected ways? I am looking for examples like: Redefining \par to make it insert a secret message between all paragraphs:
\documentclass{article}
\usepackage{amsmath,lipsum}
\title{Stupid report}
\author{John \& Jane Doe}
\begin{document}
\maketitle
\let\oldpar=\par
\def\par{\oldpar And Android is better than iPhone.\oldpar}
\lipsum[1]
[
x = \frac{ - b \pm \sqrt{b^2 - 4ac} } { 2a } .
]
\lipsum[1]
\end{document}
Another example could be to swap the signs + and -:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\let\oldplus=+
\let\oldminus=-
\catcode+=\active \catcode-=\active
\def+{\oldminus}
\def-{\oldplus}
[
x
=
\frac{-b \pm \sqrt{ b^2 - 4ac } } { 2a }
]
\end{document}
Switching to LuaTeX obviously opens up many more possibilities, e.g. you can use a callback to replace all occurrences of specific names by “Donald Duck”.
Can someone think of other tricks to make TeX behave in funny, unexpected ways?



\ducksay[snail]{Bear with me, I'm slow!}there. – Skillmon Jul 02 '21 at 19:11\typeout{Microsoft Word V5.3}– Steven B. Segletes Jul 03 '21 at 01:22;-)– Gaussler Jul 03 '21 at 11:37;-)– Gaussler Jul 03 '21 at 14:44