[texhax] \newif, \csname and \endcsname
Vafa Khalighi
vafakhlgh at gmail.com
Tue Feb 1 14:00:10 CET 2011
No worries. I got it.
\documentclass{article}
\newif\iffirst
\newif\ifsecond
\firsttrue
\newcommand{\printtest}{%
\csname iffirst\expandafter\endcsname\csname ifsecond\endcsname TT\else
TF\fi\expandafter\else\csname ifsecond\endcsname FT\else FF\fi\fi
}
\begin{document}
\printtest
\end{document}
Note to myself: I should think more before posting a question.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texhax/attachments/20110202/c2f19351/attachment.html>
More information about the texhax
mailing list