ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 01 Feb 2021 00:13:08 +0100Why doesn't Sage return `True` for `e < 3`?https://ask.sagemath.org/question/55523/why-doesnt-sage-return-true-for-e-3/I would like to know why Sage does not return `True` if I type `e < 3` or `False` for `pi > 4`.
Is there a way to have that as output?Sun, 31 Jan 2021 22:11:52 +0100https://ask.sagemath.org/question/55523/why-doesnt-sage-return-true-for-e-3/Answer by eric_g for <p>I would like to know why Sage does not return <code>True</code> if I type <code>e < 3</code> or <code>False</code> for <code>pi > 4</code>.
Is there a way to have that as output?</p>
https://ask.sagemath.org/question/55523/why-doesnt-sage-return-true-for-e-3/?answer=55525#post-id-55525You have to enforce the check of the inequality by asking for a Boolean:
sage: bool(e<3)
True
sage: bool(pi>4)
False
Mon, 01 Feb 2021 00:13:08 +0100https://ask.sagemath.org/question/55523/why-doesnt-sage-return-true-for-e-3/?answer=55525#post-id-55525