@AlexeyMalistov gave an answer to make LaTeX draw a \hline between each line in tabular without using \hline? in StackOverflow before TeX.SE existed. The same question was later asked on TeX.SE: Tabular with automatic \hline.
Malistov's answer, which successfully generates a line between each row of a table, is to add this before tabular
:
\catcode`@=11
\let \savecr \@tabularcr
\def\@tabularcr{\savecr\hline}
\catcode`@=12
I think this redefines the newline character within the tabular environment, so that an \hline
is inserted, but the code is still mostly just voodoo to me. Would someone be willing to explain how it works? Thanks.