10

Can I use AND, OR in \ifthenelse? How, can you show me examples and documents? This would make my life easier.

  • 6
    \OR and \AND see texdoc ifthen – David Carlisle Oct 7 '13 at 16:40
  • 1
    There is always Knuth, Computers and Typesetting. – John Kormylo Oct 7 '13 at 18:07
  • 1
    @JohnKormylo It exists, but it won't tell you anything about \ifthenelse – David Carlisle Oct 7 '13 at 19:47
  • 2
    besides ifthen, you should also take a look at etoolbox. – henrique Oct 7 '13 at 21:29
20
\ifthenelse{1>2 \OR 3=3}{yes}{no}

\ifthenelse{1>2 \AND 3=3}{yes}{no}

produces

yes
no

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.