In the course of attempting to out-pedant another mathematician, I wanted to \show the catcode of $ to convince myself that it was a "special" character in ordinary TeX as well as LaTeX. I was just using a "dumb tex" session (that is, I invoked tex from the commandline with no file) so what I wanted was to be able to type:
\showcatcode$
but that didn't work. In the end, I did
\count255=\catcode`$
\showthe\count255
but that just doesn't smell right. What's the best way to \show the catcode of a token?
(To be clear, the result of a \showcatcode should go to the terminal and the log, not in the document itself.)
\showtheworks for any internal integer, even strange ones like\parshape. – TH. Jun 9 '11 at 12:19